mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-26 18:21:59 +00:00
parse_ifcxml: drop the use of the removed method
This commit is contained in:
@@ -243,7 +243,7 @@ class IfcStore:
|
|||||||
IfcStore.file = ifcopenshell.open(filename)
|
IfcStore.file = ifcopenshell.open(filename)
|
||||||
return
|
return
|
||||||
elif extension.lower() == "ifcxml":
|
elif extension.lower() == "ifcxml":
|
||||||
IfcStore.file = ifcopenshell.file(ifcopenshell.ifcopenshell_wrapper.parse_ifcxml(path))
|
raise NotImplementedError("Reading .ifcXML files is not currently supported.")
|
||||||
elif prefs.should_stream:
|
elif prefs.should_stream:
|
||||||
IfcStore.file = ifcopenshell.open(path, should_stream=True)
|
IfcStore.file = ifcopenshell.open(path, should_stream=True)
|
||||||
else:
|
else:
|
||||||
|
|||||||
@@ -222,10 +222,7 @@ def open(
|
|||||||
format = guess_format(path)
|
format = guess_format(path)
|
||||||
logger = logger_or_root(logger)
|
logger = logger_or_root(logger)
|
||||||
if format == ".ifcXML":
|
if format == ".ifcXML":
|
||||||
f = ifcopenshell_wrapper.parse_ifcxml(str(path.absolute()), *((logger,) if logger is not None else ()))
|
raise NotImplementedError("Reading .ifcXML files is not currently supported.")
|
||||||
if f:
|
|
||||||
return file(f)
|
|
||||||
raise OSError(f"Failed to parse .ifcXML file from {path}")
|
|
||||||
if format == ".ifcZIP":
|
if format == ".ifcZIP":
|
||||||
with tempfile.TemporaryDirectory() as unzipped_path:
|
with tempfile.TemporaryDirectory() as unzipped_path:
|
||||||
with zipfile.ZipFile(path) as zf:
|
with zipfile.ZipFile(path) as zf:
|
||||||
|
|||||||
@@ -1640,7 +1640,6 @@ def map_shape(settings, instance): ...
|
|||||||
def nary_union(sequence): ...
|
def nary_union(sequence): ...
|
||||||
def new_IfcBaseClass(schema_identifier: str, name: str) -> entity_instance: ...
|
def new_IfcBaseClass(schema_identifier: str, name: str) -> entity_instance: ...
|
||||||
def open(fn: str, readonly: bool = False, logger=None) -> file: ...
|
def open(fn: str, readonly: bool = False, logger=None) -> file: ...
|
||||||
def parse_ifcxml(filename): ...
|
|
||||||
def polygons_to_svg(*args): ...
|
def polygons_to_svg(*args): ...
|
||||||
def read(data): ...
|
def read(data): ...
|
||||||
def register_schema(arg1): ...
|
def register_schema(arg1): ...
|
||||||
|
|||||||
Reference in New Issue
Block a user