24#ifndef PXR_USD_SDF_CHILDREN_H
25#define PXR_USD_SDF_CHILDREN_H
28#include "pxr/usd/sdf/api.h"
30#include "pxr/usd/sdf/path.h"
34PXR_NAMESPACE_OPEN_SCOPE
49template<
class ChildPolicy>
53 typedef typename ChildPolicy::KeyPolicy KeyPolicy;
54 typedef typename ChildPolicy::KeyType KeyType;
55 typedef typename ChildPolicy::ValueType ValueType;
56 typedef typename ChildPolicy::FieldType FieldType;
57 typedef Sdf_Children<ChildPolicy> This;
63 Sdf_Children(
const Sdf_Children<ChildPolicy> &other);
66 Sdf_Children(
const SdfLayerHandle &layer,
68 const KeyPolicy& keyPolicy = KeyPolicy());
76 size_t GetSize()
const;
80 ValueType GetChild(
size_t index)
const;
84 size_t Find(
const KeyType &key)
const;
89 KeyType FindKey(
const ValueType &value)
const;
93 bool IsEqualTo(
const This &other)
const;
97 bool Copy(
const std::vector<ValueType> & values,
const std::string &type);
101 bool Insert(
const ValueType& value,
size_t index,
const std::string &type);
105 bool Erase(
const KeyType& key,
const std::string &type);
108 void _UpdateChildNames()
const;
111 SdfLayerHandle _layer;
114 KeyPolicy _keyPolicy;
116 mutable std::vector<FieldType> _childNames;
117 mutable bool _childNamesValid;
120PXR_NAMESPACE_CLOSE_SCOPE
A scene description container that can combine with other such containers to form simple component as...
A path value used to locate objects in layers or scenegraphs.
Base class for all Sdf spec classes.
Token for efficient comparison, assignment, and hashing of known strings.