コード例 #1
0
 private void Initialize(AddressSpaceCompiler addressSpaceCompiler, IInstanceNode node, XmlQualifiedName nodeID, bool isInstanceDeclaration, int?parentAddressSpaceIndex)
 {
     Debug.Assert(node != null, "Parameter error at AddressSpaceNode creator: node cannot be null");
     Debug.Assert(nodeID != null, "NodeID cannot be null");
     ErrorList                 = new List <Diagnostics>();
     m_References              = new InstanceReferencesCollection(this);
     m_Compiler                = addressSpaceCompiler;
     m_IsInstanceDeclaration   = isInstanceDeclaration;
     m_ParentAddressSpaceIndex = parentAddressSpaceIndex;
     m_Node            = node;
     m_NodeID          = nodeID;
     AddressSpaceIndex = m_Compiler.AddNode2AddressSpace(this, m_NodeID.ToString());
     InstanceWrapper   = m_Node.DerivePropertyValuesFrom(null);
 }
コード例 #2
0
 internal static AddressSpaceElement CreateAddressSpaceElement(AddressSpace.NodesTableRow row, AddressSpaceCompiler parent)
 {
     return(new AddressSpaceElement(null, row, parent));
 }
コード例 #3
0
 private AddressSpaceElement(AddressSpace.ReferencesTableRow reference, AddressSpace.NodesTableRow node, AddressSpaceCompiler parent)
 {
     m_ReferenceRow = reference;
     m_NodeRow      = node;
     m_parent       = parent;
 }
コード例 #4
0
 /// <summary>
 /// Initializes a new instance of the <see cref="InstanceNodeContext"/> class that represents an instance  that is on top of inheritance chain.
 /// </summary>
 /// <param name="addressSpaceCompiler">The address space compiler.</param>
 /// <param name="node">The node.</param>
 internal InstanceNodeContext(AddressSpaceCompiler addressSpaceCompiler, IInstanceNode node)
 {
     Initialize(addressSpaceCompiler, node, node.SymbolicName, false, new Nullable <int>());
     this.RegisterInstanceNodeInAddressSpace();
 }
コード例 #5
0
 /// <summary>
 /// Initializes a new instance of the <see cref="InstanceDeclaration"/> class it represents existing child or an instance of instance declarations.
 /// </summary>
 /// <param name="space">The address space.</param>
 /// <param name="node">The node to be represented by the instance of this class.</param>
 /// <param name="nodeID">The node unique identifier - key in the directory created as the browse path.</param>
 /// <param name="parentAddressSpaceIndex">Index of the parent in the address space if exist.</param>
 /// <param name="isInstanceDeclaration">If set to <c>true</c> object of this type represents an instance declaration.</param>
 /// <param name="modelParent">The model parent.</param>
 internal InstanceNodeContext(AddressSpaceCompiler addressSpaceCompiler, IInstanceNode node, XmlQualifiedName nodeID, int?parentAddressSpaceIndex, bool isInstanceDeclaration)
 {
     Initialize(addressSpaceCompiler, node, nodeID, isInstanceDeclaration, parentAddressSpaceIndex);
 }
コード例 #6
0
 /// <summary>
 /// Initializes a new instance of the <see cref="InstanceNodesCollection"/> class.
 /// </summary>
 /// <param name="compiler">The compiler.</param>
 public InstanceNodesCollection(AddressSpaceCompiler compiler)
 {
     m_compiler = compiler;
 }