public bool AllowElement(Element elem) { SitePlanFamilyType type = SitePlanFamilyType.Block_Highrise; return(elem is FamilyInstance && FirmStandards.IsSiteBlockFamily(elem, ref type)); }
public static bool IsSiteBlockFamily(Element _elem, ref SitePlanFamilyType _type) { if (_elem is FamilyInstance == false) { return(false); } var fi = _elem as FamilyInstance; return(IsSiteBlockFamilySymbol(fi.Symbol, ref _type)); }
public static bool IsSiteBlockFamilySymbol(FamilySymbol _fs, ref SitePlanFamilyType _type) { var p = _fs.get_Parameter(FamilyTypeIDForAPI); if (p == null) { return(false); } var typeString = p.AsString(); if (typeString == null || SitePlanFamilyTypeID.ContainsKey(typeString) == false) { return(false); } _type = SitePlanFamilyTypeID[typeString]; return (_type == SitePlanFamilyType.Block_Highrise || _type == SitePlanFamilyType.Block_Stack); }
public static bool IsSiteBlockFamilySymbol(FamilySymbol _fs) { SitePlanFamilyType type = SitePlanFamilyType.Block_Highrise; return(IsSiteBlockFamilySymbol(_fs, ref type)); }