![]() |
MapLink Pro 11.1.1.0.
Envitia MapLink Pro: The Ultimate Mapping Application Toolkit
|
This help class exists to aid in serializing metadata to either a file or TSLofstream.
Static Public Member Functions | |
static void | deleteString (char *str) |
static TSLMDMetadata * | initialiseISO19139 (const char *filename, TSLMDMetadata *metadata=0, TSLXMLParser_Expat *parser=0) |
static TSLMDMetadata * | initialiseISO19139FromString (const char *metadataString, TSLMDMetadata *metadata=0, TSLXMLParser_Expat *parser=0) |
static bool | serializeISO19139 (const TSLMDMetadata *metadata, TSLofstream &outputStream, bool indent, const char *codeListPath=0, bool writeMetadataHeader=true) |
static char * | serializeISO19139ToString (const TSLMDMetadata *metadata, bool indent, const char *codeListPath=0, bool writeMetadataHeader=true) |
static char * | serializeToString (const TSLMDMetadata *metadata, bool indent, bool writeMetadataHeader=true) |
static bool | serializeWithSchemaAndXSL (const TSLMDMetadata *metadata, const char *filename, bool indent, bool writeMetadataHeader=true) |
static bool | serializeWithSchemaAndXSL (const TSLMDMetadata *metadata, TSLofstream &outputStream, bool indent, TSLMetadataFormatEnum format=TSLMetadataFormatISO19115, const char *schemaLocation=NULL, const char *stylesheetLocation=NULL, const char *codeListPath=NULL, bool writeMetadataHeader=true) |
static char * | serializeWithSchemaAndXSLToString (const TSLMDMetadata *metadata, bool indent, bool writeMetadataHeader=true) |
static bool | serializeWithSchemaAndXSL (const TSLMDMetadata *metadata, const char *filename, bool indent, const char *schemaLocation, const char *stylesheetLocation, bool writeMetadataHeader=true) |
static bool | serializeWithSchemaAndXSL (const TSLMDMetadata *metadata, TSLofstream &outputStream, bool indent, const char *schemaLocation, const char *stylesheetLocation, bool writeMetadataHeader=true) |
static char * | serializeWithSchemaAndXSLToString (const TSLMDMetadata *metadata, bool indent, const char *schemaLocation, const char *stylesheetLocation, bool writeMetadataHeader=true) |
static void | setISOFormat (TSLMetadataFormatEnum format) |
static TSLMetadataFormatEnum | getISOFormat () |
static void | setCodeListFormat (TSLMDCodeListFormatEnum format) |
static TSLMDCodeListFormatEnum | getCodeListFormat () |
static TSLMDMetadata * | initialise (const char *filename, TSLMDMetadata *metadata=0, TSLXMLParser_Expat *parser=0) |
static TSLMDMetadata * | initialise (TSLifstream &streamOfXML, TSLMDMetadata *metadata=0, TSLXMLParser_Expat *parser=0) |
static TSLMDMetadata * | initialiseFromString (const char *metadataString, TSLMDMetadata *metadata=0, TSLXMLParser_Expat *parser=0) |
static bool | serialize (const TSLMDMetadata *metadata, const char *filename, bool indent, bool writeMetadataHeader=true) |
static bool | serialize (const TSLMDMetadata *metadata, TSLofstream &outputStream, bool indent, bool writeMetadataHeader=true) |
|
static |
Deletes a string created using one of the xxxToString methods of this class.
|
static |
Gets the metadata code list format currently in use
|
static |
Query the current format used for all reading and writing of metadata.
|
inlinestatic |
Initialises a metadata object from a file.
Parameters :
filename : The file, including path (absolute or relative), to read from to. If the file does not exist, 0 is returned;
metadata : The TSLMDMetadata object to initialise, if none is provided, one is created and returned
parser : The TSLXMLParser_Expat to use, if none is provided, one is created.
|
inlinestatic |
Initialises a metadata object from a TSLifstream.
Parameters :
streamOfXML : The TSLifStream to read from.
metadata : The TSLMDMetadata object to initialise, if none is provided, one is created and returned
parser : The TSLXMLParser_Expat to use, if none is provided, one is created.
|
inlinestatic |
Initialises a metadata object from a string.
Parameters :
metadataString: The string of metadata to read from. If the string is invalid, 0 is returned;
metadata : The TSLMDMetadata object to initialise, if none is provided, one is created and returned
parser : The TSLXMLParser_Expat to use, if none is provided, one is created.
|
static |
NOTE: ISO19139 support is limited and not intended for general use.
Initialises a metadata object from a file.
Parameters :
filename : The file, including path (absolute or relative), to read from or to. If the file does not exist, 0 is returned;
metadata : The TSLMDMetadata object to initialise, if none is provided, one is created and returned
parser : The TSLXMLParser_Expat to use, if none is provided, one is created.
|
static |
Initialises a metadata object from a string.
Parameters :
metadataString: The string of metadata to read from. If the string is invalid, 0 is returned;
metadata : The TSLMDMetadata object to initialise, if none is provided, one is created and returned
parser : The TSLXMLParser_Expat to use, if none is provided, one is created.
|
inlinestatic |
Serializes a metadata object to a file.
Parameters :
metadata : The TSLMDMetadata object to serialize
filename : The file, including path (absolute or relative), to serialize to. If the file does not exist, a new one is created;
indent : Specify whether the XML should be indented and new tags appear on new lines.
|
inlinestatic |
Serializes a metadata object to a TSLofstream.
Parameters :
metadata : The TSLMDMetadata object to serialize
outputStream : The output stream to serialize to.
indent : Specify whether the XML should be indented and new tags appear on new lines.
|
static |
Serializes a metadata object to a TSLofstream.
Parameters :
metadata : The TSLMDMetadata object to serialize
outputStream : The output stream to serialize to.
indent : Specify whether the XML should be indented and new tags appear on new lines.
|
static |
Serializes a metadata object to a string. The string becomes the responsibility of the user and should be deleted using the deleteString method. If the serialization fails then null is returned.
Parameters :
metadata : The TSLMDMetadata object to serialize
indent : Specify whether the XML should be indented and new tags appear on new lines.
|
static |
Serializes a metadata object to a string. The string becomes the responsibility of the user and should be deleted using the deleteString method. If the serialization fails then null is returned.
Parameters :
metadata : The TSLMDMetadata object to serialize
indent : Specify whether the XML should be indented and new tags appear on new lines.
|
static |
Serializes a metadata object to a file, referencing the Envitia metadata W3 Schema and XSL stylesheet located on the Envitia website.
Parameters :
metadata : The TSLMDMetadata object to serialize
filename : The file, including path (absolute or relative), to serialize to. If the file does not exist, a new one is created;
indent : Specify whether the XML should be indented and new tags appear on new lines.
|
static |
Serializes a metadata object to a file, referencing the Schema and XSL stylesheet provided by the input parameters.
Parameters :
metadata : The TSLMDMetadata object to serialize
filename : The file, including path (absolute or relative), to serialize to. If the file does not exist, a new one is created;
indent : Specify whether the XML should be indented and new tags appear on new lines.
schemaLocation : The relative or absolute path to the schema, relative to the output directory of the metadata file, as specified by the filename parameter. If null is passed then no schema is referenced.
stylesheetLocation : The relative or absolute path to the stylesheet, relative to the output directory of the metadata file, as specified by the filename parameter. If null is passed then no stylesheet is referenced.
|
static |
Serializes a metadata object to a TSLofstream, referencing the Schema and XSL stylesheet provided by the input parameters.
Parameters :
metadata : The TSLMDMetadata object to serialize
outputStream : The output stream to serialize to.
indent : Specify whether the XML should be indented and new tags appear on new lines.
schemaLocation : The relative or absolute path to the schema, relative to the output directory of the metadata file, as written by the outputStream. If null is passed then no schema is referenced.
stylesheetLocation : The relative or absolute path to the stylesheet, relative to the output directory of the metadata file, as written by the outputStream. If null is passed then no stylesheet is referenced.
|
static |
Serializes a metadata object to a TSLofstream, referencing the Envitia metadata W3 Schema and XSL stylesheet located on the Envitia website.
Parameters :
metadata : The TSLMDMetadata object to serialize
outputStream : The output stream to serialize to.
indent : Specify whether the XML should be indented and new tags appear on new lines.
format: MetaData format (from enum TSLMetaDataFormat (default ISO19115)
The following parameters are only required if 'format' is TSLMetaDataFormat ISO19139:
schemaLocation: href of the schema location (default NULL)
stylesheetLocation: href of the stylesheet location (default NULL)
codeListPath: href of the path to the code list (default NULL)
|
static |
Serializes a metadata object to a string, referencing the Envitia metadata W3 Schema and XSL stylesheet located on the Envitia website. The string becomes the responsibility of the user and should be deleted using the delete String method. If the serialization fails then null is returned.
Parameters :
metadata : The TSLMDMetadata object to serialize
indent : Specify whether the XML should be indented and new tags appear on new lines.
|
static |
Serializes a metadata object to a string, referencing the Schema and XSL stylesheet provided by the input parameters. The string becomes the responsibility of the user and should be deleted using the deleteString method. If the serialization fails then null is returned.
Parameters :
metadata : The TSLMDMetadata object to serialize
indent : Specify whether the XML should be indented and new tags appear on new lines.
schemaLocation : The relative or absolute path to the schema, relative to where the metadata will be viewed from. If null is passed then no schema is referenced.
stylesheetLocation : The relative or absolute path to the stylesheet, relative to where the metadata will be viewed from. If null is passed then no stylesheet is referenced.
|
static |
Set the metadata code list format to use.
This setting will be used for all reading and writing of metadata. It will not be modified by any other method, and must be set as required by the application.
Initially this is set to TSLMDCodeListFormatBasic.
If the code list format has been set to TSLMDCodeListFormatExtensible, then the TSLXXXCodeEx classes should be queried from the metadata model, instead of the TSLXXXCode enum values.
|
static |
Set the metadata format to use.
Unless specified otherwise for a specific method, the provided metadata format will be used for all reading and all writing of metadata.