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"
32 #include <boost/iterator/iterator_facade.hpp>
35 PXR_NAMESPACE_OPEN_SCOPE
50 template<
class ChildPolicy>
54 typedef typename ChildPolicy::KeyPolicy KeyPolicy;
55 typedef typename ChildPolicy::KeyType KeyType;
56 typedef typename ChildPolicy::ValueType ValueType;
57 typedef typename ChildPolicy::FieldType FieldType;
58 typedef Sdf_Children<ChildPolicy> This;
64 Sdf_Children(
const Sdf_Children<ChildPolicy> &other);
67 Sdf_Children(
const SdfLayerHandle &layer,
69 const KeyPolicy& keyPolicy = KeyPolicy());
77 size_t GetSize()
const;
81 ValueType GetChild(
size_t index)
const;
85 size_t Find(
const KeyType &key)
const;
90 KeyType FindKey(
const ValueType &value)
const;
94 bool IsEqualTo(
const This &other)
const;
98 bool Copy(
const std::vector<ValueType> & values,
const std::string &type);
102 bool Insert(
const ValueType& value,
size_t index,
const std::string &type);
106 bool Erase(
const KeyType& key,
const std::string &type);
109 void _UpdateChildNames()
const;
112 SdfLayerHandle _layer;
115 KeyPolicy _keyPolicy;
117 mutable std::vector<FieldType> _childNames;
118 mutable bool _childNamesValid;
121 PXR_NAMESPACE_CLOSE_SCOPE
123 #endif // PXR_USD_SDF_CHILDREN_H
A unit of scene description that you combine with other units of scene description to form a shot...
Base class for all Sdf spec classes.
Token for efficient comparison, assignment, and hashing of known strings.
A path value used to locate objects in layers or scenegraphs.