This document is for a version of USD that is under development. See this page for the current release.
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
HdOverlayContainerDataSource Class Reference

Lazily composes two or more container source hierarchies Earlier entries on the containers array have stronger opinion strength for overlapping child names. More...

#include <overlayContainerDataSource.h>

+ Inheritance diagram for HdOverlayContainerDataSource:

Public Member Functions

 HD_DECLARE_DATASOURCE (HdOverlayContainerDataSource)
 
 HD_DECLARE_DATASOURCE_INITIALIZER_LIST_NEW (HdOverlayContainerDataSource, HdContainerDataSourceHandle)
 
HD_API HdOverlayContainerDataSource (std::initializer_list< HdContainerDataSourceHandle > sources)
 
HD_API HdOverlayContainerDataSource (size_t count, HdContainerDataSourceHandle *containers)
 
HD_API HdOverlayContainerDataSource (const HdContainerDataSourceHandle &src1, const HdContainerDataSourceHandle &src2)
 
HD_API HdOverlayContainerDataSource (const HdContainerDataSourceHandle &src1, const HdContainerDataSourceHandle &src2, const HdContainerDataSourceHandle &src3)
 
HD_API TfTokenVector GetNames () override
 Returns the list of names for which Get(...) is expected to return a non-null value.
 
HD_API HdDataSourceBaseHandle Get (const TfToken &name) override
 Returns the child datasource of the given name.
 
- Public Member Functions inherited from HdContainerDataSource
 HD_DECLARE_DATASOURCE_ABSTRACT (HdContainerDataSource)
 
virtual TfTokenVector GetNames ()=0
 Returns the list of names for which Get(...) is expected to return a non-null value.
 
virtual HdDataSourceBaseHandle Get (const TfToken &name)=0
 Returns the child datasource of the given name.
 

Static Public Member Functions

static HD_API HdContainerDataSourceHandle OverlayedContainerDataSources (const HdContainerDataSourceHandle &src1, const HdContainerDataSourceHandle &src2)
 Creates HdOverlayContainerDataSource from sources, but only if needed.
 
- Static Public Member Functions inherited from HdContainerDataSource
static HD_API HdDataSourceBaseHandle Get (const Handle &container, const HdDataSourceLocator &locator)
 A convenience function: given container, return the descendant identified by locator, which may be at any depth.
 

Detailed Description

Lazily composes two or more container source hierarchies Earlier entries on the containers array have stronger opinion strength for overlapping child names.

Overlapping children which are all containers themselves are returned as another instance of this class

Definition at line 20 of file overlayContainerDataSource.h.

Member Function Documentation

◆ Get()

HD_API HdDataSourceBaseHandle Get ( const TfToken name)
overridevirtual

Returns the child datasource of the given name.

This call is expected to be threadsafe.

Implements HdContainerDataSource.

◆ GetNames()

HD_API TfTokenVector GetNames ( )
overridevirtual

Returns the list of names for which Get(...) is expected to return a non-null value.

This call is expected to be threadsafe.

Implements HdContainerDataSource.

◆ OverlayedContainerDataSources()

static HD_API HdContainerDataSourceHandle OverlayedContainerDataSources ( const HdContainerDataSourceHandle &  src1,
const HdContainerDataSourceHandle &  src2 
)
static

Creates HdOverlayContainerDataSource from sources, but only if needed.

If one of given handles is null, the other handle is returned instead.


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