示例#1
0
        public static Element FromElementId(DB.Document doc, DB.ElementId id)
        {
            if (doc is null || !id.IsValid())
            {
                return(null);
            }

            if (Category.FromElementId(doc, id) is Category c)
            {
                return(c);
            }

            if (ParameterKey.FromElementId(doc, id) is ParameterKey p)
            {
                return(p);
            }

            if (LinePatternElement.FromElementId(doc, id) is LinePatternElement l)
            {
                return(l);
            }

            return(FromElement(doc.GetElement(id)));
        }
示例#2
0
 public Proxy(ParameterKey o) : base(o)
 {
     (this as IGH_GooProxy).UserString = FormatInstance();
 }
示例#3
0
 public Proxy(ParameterKey owner)
 {
     proxyOwner = owner; (this as IGH_GooProxy).UserString = FormatInstance();
 }