GetTypeByName() private method

private GetTypeByName ( string typeName ) : Type
typeName string
return System.Type
Exemplo n.º 1
0
            public ObjectContext (XamlGenerator generator, JObject jobj)
            {
                JObj = jobj;

                TokenTypeInfo parentInfo = generator.GetTypeInfo(JObj.Parent);
                TypeInfo = generator.GetTypeInfo(JObj);
                if (TypeInfo.Type == null)
                    TypeInfo.Type = parentInfo.PropertyItemType;
                if (TypeInfo.PropertyContainerType == null)
                    TypeInfo.PropertyContainerType = parentInfo.PropertyType;

                string visibility, typeName, objId;
                ParseDollarField((string)JObj[pnDollar], out visibility, out typeName, out objId);
                Visibility = visibility;
                ObjId = objId;
                if (typeName != null) {
                    TypeInfo.Type = generator.GetTypeByName(typeName);
                    TypeName = typeName;
                }
                else if (TypeInfo.Type != null) {
                    TypeName = TypeInfo.Type.Name;
                }
            }