Skip navigation links
LuciadLightspeed
2020.1.04
com.luciad.format.gml3

LuciadLightspeedClass TLcdGML3ModelEncoder

    • Constructor Detail

      • TLcdGML3ModelEncoder

        public TLcdGML3ModelEncoder()
        Deprecated. 
        Creates a new GML3 model encoder, initialized with an appropriate element adapter provider, element name provider and schema provider.
      • TLcdGML3ModelEncoder

        public TLcdGML3ModelEncoder(ILcdXMLEditableSchemaProvider aSchemaProvider,
                                    TLcdGML3ElementNameProvider aElementNameProvider)
        Deprecated. 
        Creates a new GML3 model encoder, initialized with the given schema provider, and an appropriate element name and element adapter provider.
    • Method Detail

      • setOutputStreamFactory

        public void setOutputStreamFactory(ILcdOutputStreamFactory aOutputStreamFactory)
        Deprecated. 
        Sets the output stream factory to be used by this model encoder.
        Specified by:
        setOutputStreamFactory in interface ILcdOutputStreamFactoryCapable
        Parameters:
        aOutputStreamFactory - the output stream factory to be used by this model encoder.
        Throws:
        java.lang.NullPointerException - if aOutputStreamFactory == null.
      • setSchemaLocationsMap

        public void setSchemaLocationsMap(ILcdXMLSchemaLocationsMap aSchemaLocationsMap)
        Deprecated. 
        Sets the schema locations map to be used by this encoder.
        Parameters:
        aSchemaLocationsMap - the schema locations map to be registered. #see com.luciad.format.xml.TLcdXMLEncoder#setSchemaLocationsMap
      • setDefaultNamespace

        public void setDefaultNamespace(java.lang.String aDefaultNamespace)
        Deprecated. 
        Sets the default XML namespace for the documents created by this encoder. This is the namespace for which no prefix will be used in the generated XML documents. It does not have to be the same as the target namespace.
        Parameters:
        aDefaultNamespace -
        See Also:
        TLcdXMLEncoder.setDefaultNamespace(String)
      • getDefaultNamespace

        public java.lang.String getDefaultNamespace()
        Deprecated. 
        Returns the default XML namespace used by this encoder.
        Returns:
        the default XML namespace used by this encoder.
        See Also:
        setDefaultNamespace(String)
      • getElementNameProvider

        public ILcdXMLElementNameProvider getElementNameProvider()
        Deprecated. 
        Returns the ILcdXMLElementNameProvider that is used by this encoder.
        Returns:
        the ILcdXMLElementNameProvider that is used by this encoder.
      • getElementAdapterProvider

        public ILcdXMLTypedElementAdapterProvider getElementAdapterProvider()
        Deprecated. 
        Returns the ILcdXMLTypedElementAdapterProvider that is used by this encoder.
        Returns:
        the ILcdXMLTypedElementAdapterProvider that is used by this encoder.
      • getSchemaProvider

        public ILcdXMLEditableSchemaProvider getSchemaProvider()
        Deprecated. 
        Returns the ILcdXMLSchemaProvider that is used by this encoder.
        Returns:
        the ILcdXMLSchemaProvider that is used by this encoder.
      • registerElementName

        public void registerElementName(java.lang.Class aJavaClass,
                                        TLcdXMLName aElementName)
        Deprecated. 
        Registers an element name for the given Java class.
        Parameters:
        aJavaClass - the Java class for which the name is to be registered.
        aElementName - the element name to be registered.
      • registerElementAdapter

        public void registerElementAdapter(TLcdXMLName aTypeName,
                                           java.lang.Class aJavaClass,
                                           ILcdXMLElementAdapter aElementAdapter)
        Deprecated. 
        Registers a element adapter for the given XML type name and the given Java class.
        Parameters:
        aTypeName - the XML type name for which to register the given element adapter.
        aJavaClass - the Java class for which to register the given element adapter.
        aElementAdapter - the element adapter to be registered.
      • registerElementAdapter

        public void registerElementAdapter(TLcdXMLName aTypeName,
                                           TLcdXMLName[] aElementNameStack,
                                           java.lang.Class aJavaClass,
                                           ILcdXMLElementAdapter aAdapter)
        Deprecated. 
        Registers the given adapter for the anonymous XML type, identified by the element name stack, and, if the element name stack is contained within a named type, the name of that type.
        Parameters:
        aTypeName - The XML type name from which the specified element name stack is part of.
        aElementNameStack - The element name stack, identifying the XML type within the provided XML type.
        aAdapter - the adapter to be registered.
        Throws:
        java.lang.NullPointerException - if aAdapter == null || aJavaClass == null.
      • setTargetNamespace

        public void setTargetNamespace(java.lang.String aNamespace)
        Deprecated. 
        Sets the target namespace for the XML documents to be generated. All dynamically created custom schema types and elements (feature types and feature elements) will be created within this namespace.
        Parameters:
        aNamespace -
        See Also:
        ALcdGML3ElementNameProvider.setTargetNamespace(String)
      • getTargetNamespace

        public java.lang.String getTargetNamespace()
        Deprecated. 
        Returns the target namespace of the custom schema, in which dynamically created XML schema types and elements are stored.
        Returns:
        the target namespace of the custom schema.
        See Also:
        ALcdGML3ElementNameProvider.getTargetNamespace()
      • setEncodeSchema

        public void setEncodeSchema(boolean aEncodeSchema)
        Deprecated. 
        Sets whether to encode the schema each time a model is encoded, or not. If true, the schema will be stored at the same location as the XML file, but with extension '.xsd'. If false, only the model will be encoded.
        Parameters:
        aEncodeSchema - boolean indicating whether to encode schemas or not.
      • isEncodeSchema

        public boolean isEncodeSchema()
        Deprecated. 
        Returns true if schemas are also encoded, each time a model is encoded , false otherwise.
        Returns:
        true if schemas are encoded, false otherwise.
        See Also:
        setEncodeSchema(boolean)
      • getDisplayName

        public java.lang.String getDisplayName()
        Deprecated. 
        Description copied from interface: ILcdModelEncoder
        Returns a short, displayable name for the format this ILcdModelEncoder encodes to.
        Specified by:
        getDisplayName in interface ILcdModelEncoder
        Returns:
        the displayable name of this ILcdModelEncoder.
      • canSave

        public boolean canSave(ILcdModel aModel)
        Deprecated. 
        Description copied from interface: ILcdModelEncoder
        Returns whether this model encoder can save the specified model to the location it originally came from. Often this will only be a simple test, for example checking the type of the model's model descriptor.
        Specified by:
        canSave in interface ILcdModelEncoder
        Parameters:
        aModel - the model to be verified.
        Returns:
        true if this encoder can save the model in the location where it originally came from, false otherwise.
        See Also:
        ILcdModelEncoder.save(com.luciad.model.ILcdModel)
      • save

        public void save(ILcdModel aModel)
                  throws java.lang.IllegalArgumentException,
                         java.io.IOException
        Deprecated. 
        Description copied from interface: ILcdModelEncoder
        Saves the model to the location where it originally came from.
        Specified by:
        save in interface ILcdModelEncoder
        Parameters:
        aModel - the model to be saved.
        Throws:
        java.lang.IllegalArgumentException - if the model cannot be saved by this encoder (!canSave(aModel)).
        java.io.IOException - if an I/O error occurs during encoding.
      • canExport

        public boolean canExport(ILcdModel aModel,
                                 java.lang.String aDestination)
        Deprecated. 
        Description copied from interface: ILcdModelEncoder
        Returns whether this encoder can export the specified model to the specified destination. This method will typically check whether the contents of the specified model are compatible with the format this encoder is written for.
        Specified by:
        canExport in interface ILcdModelEncoder
        Parameters:
        aModel - the model to be verified.
        aDestination - the location where the model should be exported to.
        Returns:
        true if this encoder can export the specified model to the specified location, false otherwise.
        See Also:
        ILcdModelEncoder.export(com.luciad.model.ILcdModel, java.lang.String)
      • export

        public void export(ILcdModel aModel,
                           java.lang.String aDestination)
                    throws java.lang.IllegalArgumentException,
                           java.io.IOException
        Deprecated. 
        Description copied from interface: ILcdModelEncoder
        Exports the specified model to the specified destination.
        Specified by:
        export in interface ILcdModelEncoder
        Parameters:
        aModel - the model to be exported.
        aDestination - the location where the model should be saved. Typically, this is a name for the output file, but it can also point to a file containing the required properties to create a set of data files.
        Throws:
        java.lang.IllegalArgumentException - if the model cannot be saved by this encoder (!canExport(aModel, aDestinationName)).
        java.io.IOException - if an I/O error occurs during encoding.
      • exportSchema

        public void exportSchema(ILcdModel aModel,
                                 java.lang.String aDestination)
                          throws java.lang.IllegalArgumentException,
                                 java.io.IOException
        Deprecated. 
        Exports the schema for the given model to the specified destination.
        Parameters:
        aModel - the model whose schema is to be exported.
        aDestination - the destination to which the schema should be exported.
        Throws:
        java.lang.IllegalArgumentException
        java.io.IOException
LuciadLightspeed
2020.1.04