ArcGIS Procedural Runtime  3.2.10650
List of all members | Public Types | Public Member Functions | Protected Member Functions
prt::EncoderInfo Class Referenceabstract

#include <EncoderInfo.h>

Inheritance diagram for prt::EncoderInfo:
[legend]

Public Types

enum  OptionState {
  OS_ENABLED,
  OS_DISABLED,
  OS_HIDDEN
}
 

Public Member Functions

virtual Status createValidatedOptionsAndStates (const AttributeMap *optionsIn, const AttributeMap **optionsOut, const AttributeMap **statesOut=nullptr) const =0
 
virtual const AnnotationgetAnnotation (const wchar_t *key, size_t i, Status *status=0) const =0
 
virtual const wchar_t * getDescription (Status *status=0) const =0
 
virtual const wchar_t * getExtensions (Status *status=0) const =0
 
virtual const char *const * getIconsBase64 (size_t *iconsCount, Status *status=0) const =0
 
virtual const wchar_t * getID (Status *status=0) const =0
 
virtual const wchar_t *const * getInitialShapeAttributeKeys (size_t *count, Status *status=0) const =0
 
virtual double getMerit (Status *status=0) const =0
 
virtual const wchar_t * getName (Status *status=0) const =0
 
virtual size_t getNumAnnotations (const wchar_t *key, Status *status=0) const =0
 
virtual const wchar_t *const * getOptionKeys (size_t *count, Status *status=0) const =0
 
virtual ContentType getType (Status *status=0) const =0
 
virtual AttributeMap::PrimitiveType getType (const wchar_t *key, Status *status=0) const =0
 
- Public Member Functions inherited from prt::Object
void destroy () const
 
virtual char * toXML (char *result, size_t *resultSize, Status *stat=0) const =0
 
char * toXMLDocument (char *result, size_t *resultSize, Status *stat=0) const
 

Protected Member Functions

 EncoderInfo (const EncoderInfo &)
 
- Protected Member Functions inherited from prt::Object
 Object (const Object &)
 

Detailed Description

EncoderInfo is used to return static encoder information and create a valid set of encoding options and annotated initial shape attributes. Please note that some initial shape attributes may be mandated by a specific encoder and the prtx::Encoder::validate/encode calls will fail if they are missing.

Please note, that dependencies between encoding options are not explicitly managed but expressed via the state of each option instead (OptionState). Please use the prtx::EncoderInfoBuilder to construct an EncoderInfo instance.

See also
prtx::EncoderInfoBuilder

Member Enumeration Documentation

◆ OptionState

The option states.

Enumerator
OS_ENABLED 

The option is enabled and should be RW in a potential UI.

OS_DISABLED 

The option is disabled and should be RO in a potential UI.

OS_HIDDEN 

The option is hidden and should no be visible in a potential UI.

Member Function Documentation

◆ createValidatedOptionsAndStates()

virtual Status prt::EncoderInfo::createValidatedOptionsAndStates ( const AttributeMap optionsIn,
const AttributeMap **  optionsOut,
const AttributeMap **  statesOut = nullptr 
) const
pure virtual

returns a validated copy of the encoder options and their states:

  • missing keys are inserted and set to their default value
  • unknown keys are removed
  • invalid values are set to the nearest valid or default value
  • the state of depended options are updated (e.g. disabled if an option is not used with current values of other options)
Parameters
optionsInThe options to be validated. If optionsIn is 0, a copy of the default encoder options is returned.
optionsOutThe newly created object containing the validated options. Must be destroyed by the caller.
statesOutA new instance of an AttributeMap is created with the enabled states, must be destroyed by the caller. Ignored if 0.
Returns
status.

◆ getAnnotation()

virtual const Annotation* prt::EncoderInfo::getAnnotation ( const wchar_t *  key,
size_t  i,
Status status = 0 
) const
pure virtual

Returns the i-th annotation on the encode option or initial shape attribute k. The following annotations are supported:

  • LABEL (arg1: text)
  • GROUP (arg1: text)
  • DESCRIPTION (arg1: text)
  • DIRECTORY
  • FILE(arg1..n: valid extensions without period)
  • RANGE(arg1: min, arg2: max)
  • COLOR
  • ORDER(arg1: alpha-numerical ordering value)
  • MANDATORY
Parameters
keyName of the option or initial shape attribute.
iAnnotation index.
[out]statOptional pointer to return the status.

◆ getDescription()

virtual const wchar_t* prt::EncoderInfo::getDescription ( Status status = 0) const
pure virtual
Parameters
[out]statusOptional pointer to return the status.
Returns
the description of the corresponding encoder.

◆ getExtensions()

virtual const wchar_t* prt::EncoderInfo::getExtensions ( Status status = 0) const
pure virtual
Parameters
[out]statusOptional pointer to return the status.
Returns
the extensions of the corresponding encoder separated by colons (';')

◆ getIconsBase64()

virtual const char* const* prt::EncoderInfo::getIconsBase64 ( size_t *  iconsCount,
Status status = 0 
) const
pure virtual
Parameters
iconsCountNumber of returned icons
[out]statusOptional pointer to return the status.
Returns
the encoder icon as base64-encoded PNG.

◆ getID()

virtual const wchar_t* prt::EncoderInfo::getID ( Status status = 0) const
pure virtual
Parameters
[out]statusOptional pointer to return the status.
Returns
the ID of the corresponding encoder.

◆ getInitialShapeAttributeKeys()

virtual const wchar_t* const* prt::EncoderInfo::getInitialShapeAttributeKeys ( size_t *  count,
Status status = 0 
) const
pure virtual

Returns all initial shape attribute keys which are known to the encoder.

See also
getAnnotation
getNumAnnotations
prt::InitialShapeBuilder::setAttributes

◆ getMerit()

virtual double prt::EncoderInfo::getMerit ( Status status = 0) const
pure virtual
Parameters
[out]statusOptional pointer to return the status.
Returns
the merit of the encoder. In case two encoders provide overlapping functionality, the one with the higher merit should be preferred.

◆ getName()

virtual const wchar_t* prt::EncoderInfo::getName ( Status status = 0) const
pure virtual
Parameters
[out]statusOptional pointer to return the status.
Returns
the name of the corresponding encoder.

◆ getNumAnnotations()

virtual size_t prt::EncoderInfo::getNumAnnotations ( const wchar_t *  key,
Status status = 0 
) const
pure virtual
Parameters
keyName of the option or initial shape attribute.
[out]statusOptional pointer to return the status.
Returns
the number of annotations defined on the encode option or initial shape attribute 'key'.

◆ getOptionKeys()

virtual const wchar_t* const* prt::EncoderInfo::getOptionKeys ( size_t *  count,
Status status = 0 
) const
pure virtual
Parameters
[out]countPointer to return number of keys.
[out]statusOptional pointer to return the status.
Returns
all encoder option keys.

◆ getType() [1/2]

virtual ContentType prt::EncoderInfo::getType ( Status status = 0) const
pure virtual
Parameters
[out]statusOptional pointer to return the status.
Returns
the content type this encoder can encode.

◆ getType() [2/2]

virtual AttributeMap::PrimitiveType prt::EncoderInfo::getType ( const wchar_t *  key,
Status status = 0 
) const
pure virtual
Parameters
keyName of the option or initial shape attribute.
[out]statusOptional pointer to return the status.
Returns
the type of a certain encoder option or initial shape attribute.

The documentation for this class was generated from the following file: