mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-19 06:39:13 +00:00
code formatting
This commit is contained in:
@@ -55,7 +55,6 @@ class facet(metaclass=meta_facet):
|
|||||||
try:
|
try:
|
||||||
v = self.node.getElementsByTagName(k)[0]
|
v = self.node.getElementsByTagName(k)[0]
|
||||||
elems = [n for n in v.childNodes if n.nodeType == n.ELEMENT_NODE]
|
elems = [n for n in v.childNodes if n.nodeType == n.ELEMENT_NODE]
|
||||||
|
|
||||||
if elems:
|
if elems:
|
||||||
return restriction(elems[0])
|
return restriction(elems[0])
|
||||||
else:
|
else:
|
||||||
@@ -223,8 +222,6 @@ class restriction:
|
|||||||
self.options.append(n.getAttribute("value"))
|
self.options.append(n.getAttribute("value"))
|
||||||
self.type = "pattern"
|
self.type = "pattern"
|
||||||
|
|
||||||
# "Given an instance with %(applicability)s\nWe expect %(requirements)s" % self.__dict__
|
|
||||||
|
|
||||||
def __eq__(self, other):
|
def __eq__(self, other):
|
||||||
return other in self.options
|
return other in self.options
|
||||||
|
|
||||||
@@ -290,7 +287,7 @@ class ids:
|
|||||||
def validate(self, ifc_file, logger):
|
def validate(self, ifc_file, logger):
|
||||||
for spec in self.specifications:
|
for spec in self.specifications:
|
||||||
for elem in ifc_file.by_type("IfcObject"):
|
for elem in ifc_file.by_type("IfcObject"):
|
||||||
spec(elem, logger)
|
spec(elem, logger)
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
import sys, os
|
import sys, os
|
||||||
|
|||||||
Reference in New Issue
Block a user