All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
PcpDynamicFileFormatContext Class Reference

Context object for the current state of a prim index that is being built that allows implementations of PcpDynamicFileFormatInterface to compose field values when generating dynamic file format arguments. More...

Public Types

using VtValueVector = std::vector< VtValue >
 

Public Member Functions

PCP_API bool ComposeValue (const TfToken &field, VtValue *value) const
 Compose the value of the given field and return its current strongest opinion. More...
 
PCP_API bool ComposeValueStack (const TfToken &field, VtValueVector *values) const
 Compose the values of the given field returning all available opinions ordered from strongest to weakest. More...
 

Detailed Description

Context object for the current state of a prim index that is being built that allows implementations of PcpDynamicFileFormatInterface to compose field values when generating dynamic file format arguments.

The context allows us to iterate over all nodes that have already been composed looking for the strongest opinion for a relevant field.

Definition at line 43 of file dynamicFileFormatContext.h.

Member Function Documentation

PCP_API bool ComposeValue ( const TfToken field,
VtValue value 
) const

Compose the value of the given field and return its current strongest opinion.

For dictionary valued fields this will be a dictionary containing the strongest value for each individual key. Returns true if a value for the field was found.

PCP_API bool ComposeValueStack ( const TfToken field,
VtValueVector *  values 
) const

Compose the values of the given field returning all available opinions ordered from strongest to weakest.

For dictionary valued fields, the dictionaries from each opinion are not composed together at each step and are instead returned in the list as is. Returns true if a value for the field was found.

Note that this is slower than ComposeValue, especially for non-dictionary valued fields, and should only be used if knowing more than just the strongest value is necessary.


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