Definition: | #include <CDM.h> |
---|
|
Prototype: | CDM_ByteSequence CDM_GetRawData(CDM_Document Document);
|
---|
Arguments: | Document: A Document object. (CDM_Document)
|
---|
|
|
Prototype: | char * CDM_GetRawData(CDM_Document Document, char *Encoding);
|
---|
Arguments: | Document: A Document object. (CDM_Document) Encoding: The desired encoding that the text of the Document is to be converted to. (char *)
|
---|
|
|
Prototype: | char * CDM_GetRawData(CDM_Document Document, const Tcl_Encoding encoding);
|
---|
Arguments: | Document: A Document object. (CDM_Document) Encoding: The desired encoding that the text of the Document is to be converted to. (Tcl_Encoding)
|
---|
|
|
Description:
This function will return the Text of the specified Document. It will
return an object (of type CDM_ByteSequence) that will contain the text
of the Document. The caller can use the Tcl function Tcl_GetString in
order to get the text stored in the returned object as a C pointer (of
type char*). The text will be stored using the UTF-8 encoding.
In order to convert
the returned C pointer into a specific encoding (like iso8859-1 or
iso8859-7), the function CDM_UtfToExternal can be used. Note that the returned object is owned by the CDM. The caller is not
supposed to free or modify the returned object.
char * CDM_GetRawData(CDM_Document Document, char *Encoding): |
This function will return the Text of the specified Document. It will
return a C pointer (of type char*) that will contain the text
of the Document. The text will be stored in a newly allocated memory
space, using the requested by the value of the "Encoding" parameter
encoding. The pointer to that new memory segment will be returned to
the caller. Note that the returned object is not owned by the CDM. The caller is
responsible to use CDM_Free (or Tcl_Free) in order to free the string and
the memory associated with it.
char * CDM_GetRawData(CDM_Document Document, const Tcl_Encoding encoding): |
This function will return the Text of the specified Document. It will
return a C pointer (of type char*) that will contain the text
of the Document. The text will be stored in a newly allocated memory
space, using the requested by the value of the "Encoding" parameter
encoding. The pointer to that new memory segment will be returned to
the caller. Note that the returned object is not owned by the CDM. The caller is
responsible to use CDM_Free (or Tcl_Free) in order to free the string and
the memory associated with it.
Return Value:
This function will return a Text object (of type CDM_ByteSequence) that
will contain the text (or byte sequence or raw data) of the specified
Document. The returned object is property of the CDM and should never be
freed or modified in any way by the caller.char * CDM_GetRawData(CDM_Document Document, char *Encoding): |
This function will return a C pointer (of type char*) that
will contain the text (or byte sequence or raw data) of the specified
Document encoded in the requested encoding. CDM does not own the
returned memory segment: the caller is responsible to use CDM_Free (or
Tcl_Free) in order to free the string and the memory associated with it.char * CDM_GetRawData(CDM_Document Document, const Tcl_Encoding encoding): |
This function will return a C pointer (of type char*) that
will contain the text (or byte sequence or raw data) of the specified
Document encoded in the requested encoding. CDM does not own the
returned memory segment: the caller is responsible to use CDM_Free (or
Tcl_Free) in order to free the string and the memory associated with it.
Notes:
This function is equivelant to tip_GetByteSequence (Tcl API).char * CDM_GetRawData(CDM_Document Document, char *Encoding): |
This function does not have an equivelant function (Tcl API). The Tcl
core uses UTF-8 as its native encoding, so the convertion to a specific
encoding is not needed.char * CDM_GetRawData(CDM_Document Document, const Tcl_Encoding encoding): |
This function does not have an equivelant function (Tcl API). The Tcl
core uses UTF-8 as its native encoding, so the convertion to a specific
encoding is not needed.
See Also:
CDM_GetByteSequence, CDM_UtfToExternal, tip_GetByteSequencechar * CDM_GetRawData(CDM_Document Document, char *Encoding): |
CDM_Free, CDM_GetByteSequence, Tcl_Freechar * CDM_GetRawData(CDM_Document Document, const Tcl_Encoding encoding): |
CDM_Free, CDM_GetByteSequence, Tcl_GetEncoding, Tcl_Free
Generated by: petasis@aias on Wed Aug 16 10:31:57 PM EEST 2006.