From 3466a38a448c6874faddf9d3118565ace4af5fb9 Mon Sep 17 00:00:00 2001 From: Gorgious Date: Mon, 31 Oct 2022 10:32:49 +0100 Subject: [PATCH] Removed hardcoded descriptions thanks to 937f39c --- src/blenderbim/blenderbim/bim/prop.py | 25 ++++++------------------- 1 file changed, 6 insertions(+), 19 deletions(-) diff --git a/src/blenderbim/blenderbim/bim/prop.py b/src/blenderbim/blenderbim/bim/prop.py index e607fdd464..a141ab8ee4 100644 --- a/src/blenderbim/blenderbim/bim/prop.py +++ b/src/blenderbim/blenderbim/bim/prop.py @@ -131,26 +131,13 @@ def get_predefined_type_description(entity, predefined_type): return "" -HARDCODED_ATTRIBUTE_DESCRIPTIONS = { - "GlobalId": "Assignment of a globally unique identifier within the entire software world.", - "OwnerHistory": "Assignment of the information about the current ownership of that object, including owning actor, application, local identification and information captured about the recent changes of the object, NOTE only the last modification in stored - either as addition, deletion or modification.", - "Name": "Optional name for use by the participating software systems or users. For some subtypes of IfcRoot the insertion of the Name attribute may be required. This would be enforced by a where rule. ", - "Description": "Optional description, provided for exchanging informative comments.", - "PredefinedType": "Predefined generic type for a window that is specified in an enumeration. There may be a property set given specificly for the predefined types. NOTE The PredefinedType shall only be used, if no IfcWindowType is assigned, providing its own IfcWindowType.PredefinedType.", - "ObjectType": "The type denotes a particular type that indicates the object further. The use has to be established at the level of instantiable subtypes. In particular it holds the user defined type, if the enumeration of the attribute PredefinedType is set to USERDEFINED.", - "Tag": "The tag (or label) identifier at the particular instance of a product, e.g. the serial number, or the position number. It is the identifier at the occurrence level.", -} - - def get_attribute_description(entity, attribute): - doc = HARDCODED_ATTRIBUTE_DESCRIPTIONS.get(attribute, None) - if doc is None: - schema = tool.Ifc.get_schema() - if schema is not None: - try: - doc = get_attribute_doc(schema, entity, attribute) - except KeyError: # This entity doesn't have any attribute or doesn't implement this attribute - pass + schema = tool.Ifc.get_schema() + if schema is not None: + try: + doc = get_attribute_doc(schema, entity, attribute) + except KeyError: # This entity doesn't have any attribute or doesn't implement this attribute + pass return doc