AbstractAbstractdecodeDecodes the server response from an arbitrary format to a Cursor of
Feature instances. Note that by returning a Cursor it is possible
to perform lazy decoding (only decoding the Feature when it is requested).
The decoding options
A Cursor of Features corresponding to the
server response. All Features should be defined in the same reference.
AbstractencodeEncodes a Feature instances into an
arbitrary representation, specific to this Codec. This is an optional method.
The encoded version of the features
Encodes Feature instances to an arbitrary format and decodes that arbitrary format to LuciadRIA Feature instances.
A
Codecis typically used by a Store to decode the server response and to encode the LuciadRIAFeaturesso they can be sent back to the server. Consult the class documentation of theStoreclass for more information.Note: most of the methods in the API are optional. The presence of such an optional method indicates support for that feature. For instance a
Storewhich is read-only only needs aCodecwhich provides adecodemethod but does not need anencodemethod. It is up to theStoreimplementations to clearly document which methods they require to be present on theCodec.Users of this class should always check whether such an optional method is available before calling the method, as illustrated below: