MCPcopy Create free account
hub / github.com/FirebirdSQL/firebird / makeEncode64

Function makeEncode64

src/jrd/SysFunction.cpp:1536–1553  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1534
1535
1536void makeEncode64(DataTypeUtilBase* dataTypeUtil, const SysFunction* function, dsc* result, int argsCount, const dsc** args)
1537{
1538 fb_assert(argsCount == 1);
1539 if (args[0]->isBlob())
1540 result->makeBlob(isc_blob_text, ttype_ascii);
1541 else if (args[0]->isText())
1542 {
1543 unsigned len = encodeLen(args[0]->getStringLength());
1544 if (len <= MAX_VARY_COLUMN_SIZE)
1545 result->makeVarying(len, ttype_ascii);
1546 else
1547 result->makeBlob(isc_blob_text, ttype_ascii);
1548 }
1549 else
1550 status_exception::raise(Arg::Gds(isc_tom_strblob));
1551
1552 result->setNullable(args[0]->isNullable());
1553}
1554
1555
1556void makeDecodeHex(DataTypeUtilBase* dataTypeUtil, const SysFunction* function, dsc* result, int argsCount, const dsc** args)

Callers

nothing calls this directly

Calls 10

encodeLenFunction · 0.85
raiseFunction · 0.85
GdsClass · 0.85
isBlobMethod · 0.80
makeBlobMethod · 0.80
isTextMethod · 0.80
getStringLengthMethod · 0.80
makeVaryingMethod · 0.80
setNullableMethod · 0.80
isNullableMethod · 0.45

Tested by

no test coverage detected