Beispiel #1
0
 public ktXMLNode(ktNode Node)
     : base(Node)
 {
     //ktDebug.Log( "ktXMLNode( ktNode )" );
 }
Beispiel #2
0
        public bool AddClass(ktClass Class)
        {
            if (Class == null)
                return false;

            if (m_Classes == null)
                m_Classes = new ktList();

            ktNode Node = new ktNode(Class);
            Node.Name = Class.Name;

            return m_Classes.Add(Node);
        }
Beispiel #3
0
        public bool AddVariable(ktValue Value, bool ABKT)
        {
            // No Var??
            if (Value == null)
            {
                return false;
            }

            // Create var. list if not set 
            if (m_Variables == null)
            {
                m_Variables = new ktList();
            }

            Value.AddedByKT = ABKT;

            // Create a new node (with name and var), and add it
            ktNode Node = new ktNode(Value.Name, Value, ABKT);
            return m_Variables.AddNode(Node);
        }
Beispiel #4
0
        /// <summary>
        /// This function will add an node to the list
        /// </summary>
        /// <param name="Node">The node to add</param>
        public bool AddNode(ktNode Node)
        {
            // Can't add nothing...
            if (Node == null)
                return false; // TODO: throw exception??

            // Create a new list
            ktList List = new ktList();
            // Set the node
            List.m_Node = Node;

            // Add the list/node
            return AddList(List);
        }
Beispiel #5
0
        public ktList(ktList List)
            : this()
        {
            if (List == null)
            {
                return;
            }

            if (List.Node != null)
            {
                m_Node = new ktNode(List.Node);
            }
            else
            {
                m_Node = null;
            }

            List.Reset();
            foreach (ktList L in List)
            {
                AddList(new ktList(L));
            }
        }
Beispiel #6
0
 public ktNode(ktNode Node)
     : base("ktNode", 0)
 {
     Name = Node.Name;
     Value = Node.Value;
 }