/// <summary> /// Adds a new isContainedIn edge to the node. /// </summary> /// <param name="nodeId">[in] The end point of the new isContainedIn edge.</param> /// <param name="acValue">[in] The value of the association class.</param> /// <exception cref="Columbus.Lim.Asg.LimException">Throws LimException if the given nodeId is invalid.</exception> public void addIsContainedIn(uint nodeId, SourcePosition acValue) { if (!fact.getExist(nodeId)) { throw new LimException("Columbus.Lim.Asg.Nodes.Logical.Member.addIsContainedIn(NodeId)", "The end point of the edge does not exist."); } Columbus.Lim.Asg.Nodes.Base.Base node = fact.getRef(nodeId); if (Common.getIsBaseClassKind(node.NodeKind, Types.NodeKind.ndkFile)) { ListIteratorAssoc <Columbus.Lim.Asg.Nodes.Physical.File> .AssocEdge ac = new ListIteratorAssoc <Columbus.Lim.Asg.Nodes.Physical.File> .AssocEdge(); ac.assocClass = new ListIteratorAssoc <Columbus.Lim.Asg.Nodes.Physical.File> .AssocClass(); ac.id = nodeId; ac.assocClass.acSourcePosition = acValue; isContainedInAssocContainer.AddLast(ac); } else { throw new LimException("Columbus.Lim.Asg.Nodes.Logical.Member.setIsContainedIn(NodeId)", "Invalid NodeKind (" + node.NodeKind.ToString() + ")."); } if (fact.ReverseEdges != null) { fact.ReverseEdges.insertEdge(nodeId, this.Id, Types.EdgeKind.edkMember_IsContainedIn); } }
/// <summary> /// Adds a new hasArguments edge to the node. /// </summary> /// <param name="nodeId">[in] The end point of the new hasArguments edge.</param> /// <param name="acValue">[in] The value of the association class.</param> /// <exception cref="Columbus.Lim.Asg.LimException">Throws LimException if the given nodeId is invalid.</exception> public void addHasArguments(uint nodeId, Types.TypeArgumentConstraintKind acValue) { if (!fact.getExist(nodeId)) { throw new LimException("Columbus.Lim.Asg.Nodes.Logical.MethodGenericSpec.addHasArguments(NodeId)", "The end point of the edge does not exist."); } Columbus.Lim.Asg.Nodes.Base.Base node = fact.getRef(nodeId); if (Common.getIsBaseClassKind(node.NodeKind, Types.NodeKind.ndkType)) { ListIteratorAssoc <Columbus.Lim.Asg.Nodes.Type.Type> .AssocEdge ac = new ListIteratorAssoc <Columbus.Lim.Asg.Nodes.Type.Type> .AssocEdge(); ac.assocClass = new ListIteratorAssoc <Columbus.Lim.Asg.Nodes.Type.Type> .AssocClass(); ac.id = nodeId; ac.assocClass.acTypeArgumentConstraintKind = acValue; hasArgumentsAssocContainer.AddLast(ac); } else { throw new LimException("Columbus.Lim.Asg.Nodes.Logical.MethodGenericSpec.setHasArguments(NodeId)", "Invalid NodeKind (" + node.NodeKind.ToString() + ")."); } if (fact.ReverseEdges != null) { fact.ReverseEdges.insertEdge(nodeId, this.Id, Types.EdgeKind.edkMethodGenericSpec_HasArguments); } }
/// <summary> /// Adds a new dependsOn edge to the node. /// </summary> /// <param name="nodeId">[in] The end point of the new dependsOn edge.</param> /// <param name="acValue">[in] The value of the association class.</param> /// <exception cref="Columbus.Lim.Asg.LimException">Throws LimException if the given nodeId is invalid.</exception> public void addDependsOn(uint nodeId, string acValue) { if (!fact.getExist(nodeId)) { throw new LimException("Columbus.Lim.Asg.Nodes.Base.Named.addDependsOn(NodeId)", "The end point of the edge does not exist."); } Columbus.Lim.Asg.Nodes.Base.Base node = fact.getRef(nodeId); if (Common.getIsBaseClassKind(node.NodeKind, Types.NodeKind.ndkNamed)) { ListIteratorAssoc <Columbus.Lim.Asg.Nodes.Base.Named> .AssocEdge ac = new ListIteratorAssoc <Columbus.Lim.Asg.Nodes.Base.Named> .AssocEdge(); ac.assocClass = new ListIteratorAssoc <Columbus.Lim.Asg.Nodes.Base.Named> .AssocClass(); ac.id = nodeId; ac.assocClass.acString = Convert.ToString(fact.StringTable.set(acValue)); dependsOnAssocContainer.AddLast(ac); } else { throw new LimException("Columbus.Lim.Asg.Nodes.Base.Named.setDependsOn(NodeId)", "Invalid NodeKind (" + node.NodeKind.ToString() + ")."); } if (fact.ReverseEdges != null) { fact.ReverseEdges.insertEdge(nodeId, this.Id, Types.EdgeKind.edkNamed_DependsOn); } }
/// <summary> /// Loads the node. /// </summary> /// <param name="io">[in] The node is read from io.</param> /// <exception cref="Columbus.ColumbusIOException">Throws ColumbusIOException if there is something wrong with the file.</exception> public override void load(IO binIo) { base.load(binIo); m_specialize = binIo.readUInt4(); uint _id; _id = binIo.readUInt4(); while (_id != 0) { Types.TypeArgumentConstraintKind _ac = (Types.TypeArgumentConstraintKind)(binIo.readUByte1()); ListIteratorAssoc <Columbus.Lim.Asg.Nodes.Type.Type> .AssocEdge hasArgumentsAc = new ListIteratorAssoc <Columbus.Lim.Asg.Nodes.Type.Type> .AssocEdge(); hasArgumentsAc.assocClass.acTypeArgumentConstraintKind = _ac; hasArgumentsAc.id = _id; hasArgumentsAssocContainer.AddLast(hasArgumentsAc); _id = binIo.readUInt4(); } }
/// <summary> /// Loads the node. /// </summary> /// <param name="io">[in] The node is read from io.</param> /// <exception cref="Columbus.ColumbusIOException">Throws ColumbusIOException if there is something wrong with the file.</exception> public override void load(IO binIo) { base.load(binIo); m_hasReturnType = binIo.readUInt4(); uint _id; _id = binIo.readUInt4(); while (_id != 0) { Types.ParameterKind _ac = (Types.ParameterKind)(binIo.readUByte1()); ListIteratorAssoc <Columbus.Lim.Asg.Nodes.Type.Type> .AssocEdge hasParameterTypeAc = new ListIteratorAssoc <Columbus.Lim.Asg.Nodes.Type.Type> .AssocEdge(); hasParameterTypeAc.assocClass.acParameterKind = _ac; hasParameterTypeAc.id = _id; hasParameterTypeAssocContainer.AddLast(hasParameterTypeAc); _id = binIo.readUInt4(); } }
/// <summary> /// Loads the node. /// </summary> /// <param name="io">[in] The node is read from io.</param> /// <exception cref="Columbus.ColumbusIOException">Throws ColumbusIOException if there is something wrong with the file.</exception> public override void load(IO binIo) { base.load(binIo); m_name = binIo.readUInt4(); uint _id; _id = binIo.readUInt4(); while (_id != 0) { string _ac = binIo.readUInt4().ToString(); ListIteratorAssoc <Columbus.Lim.Asg.Nodes.Base.Named> .AssocEdge dependsOnAc = new ListIteratorAssoc <Columbus.Lim.Asg.Nodes.Base.Named> .AssocEdge(); dependsOnAc.assocClass.acString = _ac; dependsOnAc.id = _id; dependsOnAssocContainer.AddLast(dependsOnAc); _id = binIo.readUInt4(); } }
/// <summary> /// Loads the node. /// </summary> /// <param name="io">[in] The node is read from io.</param> /// <exception cref="Columbus.ColumbusIOException">Throws ColumbusIOException if there is something wrong with the file.</exception> public override void load(IO binIo) { base.load(binIo); byte boolValues = binIo.readUByte1(); m_isRealInstance = Convert.ToBoolean(boolValues & 1); boolValues >>= 1; uint _id; _id = binIo.readUInt4(); while (_id != 0) { Types.TypeArgumentConstraintKind _ac = (Types.TypeArgumentConstraintKind)(binIo.readUByte1()); ListIteratorAssoc <Columbus.Lim.Asg.Nodes.Type.Type> .AssocEdge hasArgumentsAc = new ListIteratorAssoc <Columbus.Lim.Asg.Nodes.Type.Type> .AssocEdge(); hasArgumentsAc.assocClass.acTypeArgumentConstraintKind = _ac; hasArgumentsAc.id = _id; hasArgumentsAssocContainer.AddLast(hasArgumentsAc); _id = binIo.readUInt4(); } }
/// <summary> /// Loads the node. /// </summary> /// <param name="io">[in] The node is read from io.</param> /// <exception cref="Columbus.ColumbusIOException">Throws ColumbusIOException if there is something wrong with the file.</exception> public override void load(IO binIo) { base.load(binIo); byte boolValues = binIo.readUByte1(); m_isStatic = Convert.ToBoolean(boolValues & 1); boolValues >>= 1; m_isCompilerGenerated = Convert.ToBoolean(boolValues & 1); boolValues >>= 1; m_accessibility = (Types.AccessibilityKind)binIo.readUByte1(); m_commentLines = binIo.readUInt4(); m_demangledName = binIo.readUInt4(); m_language = (Types.LanguageKind)binIo.readUByte1(); m_mangledName = binIo.readUInt4(); m_aggregated = binIo.readUInt4(); m_declares = binIo.readUInt4(); m_languageVariant = binIo.readUInt4(); uint _id; _id = binIo.readUInt4(); while (_id != 0) { belongsToContainer.AddLast(_id); _id = binIo.readUInt4(); } _id = binIo.readUInt4(); while (_id != 0) { compilationUnitContainer.AddLast(_id); _id = binIo.readUInt4(); } _id = binIo.readUInt4(); while (_id != 0) { hasCommentContainer.AddLast(_id); _id = binIo.readUInt4(); } _id = binIo.readUInt4(); while (_id != 0) { instanceContainer.AddLast(_id); _id = binIo.readUInt4(); } _id = binIo.readUInt4(); while (_id != 0) { SourcePosition _ac = new SourcePosition(); _ac.load(binIo); ListIteratorAssoc <Columbus.Lim.Asg.Nodes.Physical.File> .AssocEdge isContainedInAc = new ListIteratorAssoc <Columbus.Lim.Asg.Nodes.Physical.File> .AssocEdge(); isContainedInAc.assocClass.acSourcePosition = _ac; isContainedInAc.id = _id; isContainedInAssocContainer.AddLast(isContainedInAc); _id = binIo.readUInt4(); } _id = binIo.readUInt4(); while (_id != 0) { usesContainer.AddLast(_id); _id = binIo.readUInt4(); } _id = binIo.readUInt4(); while (_id != 0) { variantContainer.AddLast(_id); _id = binIo.readUInt4(); } }