lookupType() public method

Look for a binding named {@code name} and if found, return its type.
public lookupType ( string name ) : DataType
name string
return DataType
Beispiel #1
0
        ModuleType GetCachedModule(string file)
        {
            DataType t = ModuleTable.lookupType(GetModuleQname(file));

            if (t == null)
            {
                return(null);
            }
            else if (t is UnionType)
            {
                foreach (DataType tt in ((UnionType)t).types)
                {
                    if (tt is ModuleType)
                    {
                        return((ModuleType)tt);
                    }
                }
                return(null);
            }
            else if (t is ModuleType)
            {
                return((ModuleType)t);
            }
            else
            {
                return(null);
            }
        }