public override Type GetObjType(Type propertyType, string name) { if (ObjectType != null) { return(ObjectType); } return(ObjectUtil.GetDictionaryValueType(propertyType, name, this)); }
private static BaseDictionaryAttribute GetDictionaryAttribute(object receiver, QName root) { Type valueType = ObjectUtil.GetDictionaryValueType(receiver.GetType(), "", null); ITkTypeConverter converter = TkTypeDescriptor.GetSimpleConverter(valueType); BaseDictionaryAttribute attr; if (converter == null) { attr = new ObjectDictionaryAttribute { ObjectType = valueType } } ; else { attr = new DictionaryAttribute { ObjectType = valueType } }; attr.Assign(root); return(attr); }