public Part LookupType(string Namespace, string type) { TypeDB tdb = namespaces [Namespace] as TypeDB; Console.WriteLine("lookup namespace: {0} type: {1}", Namespace, type); if (tdb != null) { TypeRecord tr = tdb [type]; if (tr != null) { return(tr.part); } } return(null); }
public Part LookupMember(string Namespace, string type, string member) { TypeDB tdb = namespaces [Namespace] as TypeDB; Console.WriteLine("lookup {0}.{1}.{2}", Namespace, type, member); if (tdb != null) { TypeRecord tr = tdb [type]; if (tr != null) { return(tr.MemberDB [member]); } } return(null); }
public void AddType(string Namespace, string type, Part part) { TypeDB tdb = this [Namespace] as TypeDB; Console.WriteLine("add type namespace: {0} type: {1}", Namespace, type); if (tdb == null) { tdb = this [Namespace] = new TypeDB(); } TypeRecord tr = tdb [type]; if (tr == null) { tdb [type] = new TypeRecord(type, part); } else { tr.part = part; } }
public void AddMember(string Namespace, string type, string member, Part part) { TypeDB tdb = this [Namespace] as TypeDB; Console.WriteLine("add {0}.{1}.{2}", Namespace, type, member); if (tdb == null) { tdb = this [Namespace] = new TypeDB(); } TypeRecord tr = tdb [type]; if (tr == null) { tr = tdb [type] = new TypeRecord(type); types++; } if (tr.MemberDB [member] == null) { members++; } tr.MemberDB [member] = part; }
public void AddType (string Namespace, string type, Part part) { TypeDB tdb = this [Namespace] as TypeDB; Console.WriteLine ("add type namespace: {0} type: {1}", Namespace, type); if (tdb == null) tdb = this [Namespace] = new TypeDB (); TypeRecord tr = tdb [type]; if (tr == null) tdb [type] = new TypeRecord (type, part); else tr.part = part; }
public void AddMember (string Namespace, string type, string member, Part part) { TypeDB tdb = this [Namespace] as TypeDB; Console.WriteLine ("add {0}.{1}.{2}", Namespace, type, member); if (tdb == null) tdb = this [Namespace] = new TypeDB (); TypeRecord tr = tdb [type]; if (tr == null) { tr = tdb [type] = new TypeRecord (type); types ++; } if (tr.MemberDB [member] == null) members ++; tr.MemberDB [member] = part; }