scide: implement selectionLength for openDocument
[supercollider.git] / external_libraries / yaml-cpp-0.3.0 / src / nodeownership.cpp
blob118edbc84b402444f25bcf7aad1a76302c2ea69d
1 #include "nodeownership.h"
2 #include "yaml-cpp/node.h"
4 namespace YAML
6 NodeOwnership::NodeOwnership(NodeOwnership *pOwner): m_pOwner(pOwner)
8 if(!m_pOwner)
9 m_pOwner = this;
12 NodeOwnership::~NodeOwnership()
16 Node& NodeOwnership::_Create()
18 m_nodes.push_back(std::auto_ptr<Node>(new Node));
19 return m_nodes.back();
22 void NodeOwnership::_MarkAsAliased(const Node& node)
24 m_aliasedNodes.insert(&node);
27 bool NodeOwnership::_IsAliased(const Node& node) const
29 return m_aliasedNodes.count(&node) > 0;