Qore Programming Language Reference Manual  0.8.13
Pseudo_QC_Binary.dox.h
1 namespace Qore {
4 /***/
5 class <binary> : public <value> {
6 
7 public:
9 
21 bool empty();
22 
23 public:
25 
37 int size();
38 
39 public:
41 
50 bool sizep();
51 
52 public:
54 
70 list split(binary sep);
71 
72 public:
74 
93 binary substr(softint start);
94 
95 public:
97 
117 binary substr(softint start, softint len);
118 
119 public:
121 
141 string toBase64(softint maxlinelen = -1);
142 
143 public:
145 
162 string toHex();
163 
164 public:
166 
190 string toMD5();
191 
192 public:
194 
216 string toSHA1();
217 
218 public:
220 
246 string toSHA224();
247 
248 public:
250 
276 string toSHA256();
277 
278 public:
280 
306 string toSHA384();
307 
308 public:
310 
336 string toSHA512();
337 
338 public:
340 
354 string toString(*string encoding);
355 
356 public:
358 
372 int typeCode();
373 
374 public:
376 
392 bool val();
393 };
394 };
bool val()
Returns False if the binary object is empty (size = 0), True if not.
bool sizep()
Returns True since binary objects can return a non-zero size.
Methods in this pseudo-class are available to be executed on any value type (even NOTHING); this is t...
Definition: Pseudo_QC_All.dox.h:5
bool empty()
Returns True if the binary object is empty (size = 0), False if not.
string toSHA256()
Returns the SHA-256 message digest (a variant of SHA-2) of the binary data as a hex string...
binary substr(softint start)
Returns a portion of the binary data starting from an integer offset.
string toSHA1()
Returns the SHA1 message digest of the binary data as a hex string.
string toMD5()
Returns the MD5 message digest of the binary data as a hex string.
binary binary()
Always returns an empty binary object (of zero length)
string toSHA512()
Returns the SHA-512 message digest (a variant of SHA-2) of the binary data as a hex string...
list split(binary sep)
Returns a list of binary objects representing each component of the binary object separated by the by...
list list(...)
Returns an untyped list of the arguments passed at the top level.
string toBase64(softint maxlinelen=-1)
Returns the base64-encoded representation of the binary object.
Methods in this pseudo-class can be executed on binary values.
Definition: Pseudo_QC_Binary.dox.h:5
int typeCode()
Returns Qore::NT_BINARY.
int size()
Returns the number of bytes in the binary object.
string toSHA384()
Returns the SHA-384 message digest (a variant of SHA-2) of the binary data as a hex string...
string toHex()
returns a string of hexadecimal digits corresponding to the contents of the binary object ...
main Qore-language namespace
Definition: Pseudo_QC_All.dox.h:2
string toSHA224()
Returns the SHA-224 message digest (a variant of SHA-2) of the binary data as a hex string...
string toString()
Returns the string representation of the value; the default is an empty string.