private TypeStructure getNewTypeStructure <T>(PropertyInfo objectType, Models.ItemType type, ClassContainter <T> classContainter) { var paramterStructure = new TypeStructure { Attributes = objectType.GetCustomAttributes().ToDictionary(a => a.GetType().Name, b => b), IsSytemType = type.IsSystem, Type = type.Type, IsArray = type.IsArray, Name = objectType.Name, TypeName = type.Type.Name }; return(paramterStructure); }
private TypeStructure getNewTypeStructuree <T>(ClassContainter <T> classContainter, ParameterInfo parameter, MethodStructure method, Models.ItemType objectType) { var paramterStructure = new TypeStructure { Attributes = filterAndMapAttributesToDictionary(parameter.GetCustomAttributes(), classContainter), IsSytemType = objectType.IsSystem, Name = parameter.Name, Type = objectType.Type, TypeName = objectType.Type.Name, IsArray = objectType.Type.IsArray }; method.Parameters.Add(new TypeStructure(paramterStructure)); if (!paramterStructure.IsSytemType && !classContainter.Models.ContainsKey(paramterStructure.TypeName)) { classContainter.Models[paramterStructure.TypeName] = paramterStructure; } return(paramterStructure); }
private bool shouldProcessParameter(Models.ItemType objectType, TypeStructure parameterStructure) { return(!parameterStructure.IsSytemType && AppDomain.CurrentDomain.GetAssemblies().Contains(objectType.Type.Assembly)); }