public MyFamilyParameter(FamilyParameter param) { List_AssociatedParameters = new List <MyParameter>(); InternalDefinition def = param.Definition as InternalDefinition; Name = def.Name; if (param.IsShared) { ParamType = MyParameterType.Shared; } else { if (def.BuiltInParameter == BuiltInParameter.INVALID) { ParamType = MyParameterType.Family; } else { ParamType = MyParameterType.Builtin; } } IsInstance = param.IsInstance; HaveFormula = param.IsDeterminedByFormula; Formula = param.Formula; IsReporting = param.IsReporting; foreach (Parameter asparam in param.AssociatedParameters) { MyParameter myasparam = new MyParameter(asparam, false); List_AssociatedParameters.Add(myasparam); } Units = Enum.GetName(typeof(StorageType), param.StorageType); }
public BasicFamilySettings(Family fam) { List_OrderParameters = new List <MyParameter>(); foreach (Parameter p in fam.GetOrderedParameters()) { MyParameter mp = new MyParameter(p, true); List_OrderParameters.Add(mp); } }