importIFClegacy.IfcWriter Class Reference

Public Member Functions

def addBuilding (self, placement=None, name="Default building", description=None)
 
def addColor (self, rgb, rep)
 
def addExtrudedCircle (self, data, extrusion, placement=None, color=None)
 
def addExtrudedCompositeCurve (self, curves, extrusion, placement=None, color=None)
 
def addExtrudedEllipse (self, data, extrusion, placement=None, color=None)
 
def addExtrudedPolyline (self, points, extrusion, placement=None, color=None)
 
def addExtrusion (self, profile, extrusion, placement=None)
 
def addFace (self, face)
 
def addFacetedBrep (self, faces, color=None)
 
def addGroup (self, entities, name="Default group", description=None)
 
def addPlacement (self, reference=None, origin=(0, 0, 0), xaxis=(1, 0, 0), zaxis=(0, 0, 1), local=True, flat=False)
 
def addProduct (self, elttype, shapes, storey=None, placement=None, name="Unnamed element", description=None, extra=None)
 
def addProfile (self, ifctype, data, curvetype="AREA")
 
def addRepresentations (self, shapes)
 
def addSite (self, placement=None, name="Site", description=None, latitude=None, longitude=None, elevation=None, landtitlenumber=None, address=None)
 
def addStorey (self, building=None, placement=None, name="Default storey", description=None)
 
def findByName (self, ifctype, name)
 
def union (self, solids)
 
def write (self, fp=None)
 

Public Attributes

 BuildingProducts
 
 Buildings
 
 FilePath
 
 fpoints
 
 frefs
 
 Name
 
 Organization
 
 Owner
 
 Project
 
 Site
 
 Storeys
 

Detailed Description

IfcWriter([filepath,name,owner,organization,application,version])
Creates an empty IFC document.

Member Function Documentation

◆ addBuilding()

def importIFClegacy.IfcWriter.addBuilding (   self,
  placement = None,
  name = "Default building",
  description = None 
)
addBuilding([placement,name,description]): adds a building

References importIFClegacy.IfcWriter._fileobject, importIFClegacy.IfcWriter._owner, Image::ImageBase._owner, ifc2x3.ifcasset._owner, ifc4.ifcasset._owner, importIFClegacy.IfcWriter._relate(), importIFClegacy.IfcWriter.addPlacement(), importIFClegacy.IfcWriter.addSite(), importIFClegacy.IfcWriter.Buildings, importIFClegacy.create(), importIFClegacy.IfcWriter.Site, and importIFClegacy.uid().

Referenced by importIFClegacy.IfcWriter.addStorey().

◆ addColor()

def importIFClegacy.IfcWriter.addColor (   self,
  rgb,
  rep 
)
addColor(rgb,rep): adds a RGB color definition tuple (float,float,float) to a given representation

References importIFClegacy.IfcWriter._fileobject, and importIFClegacy.create().

Referenced by importIFClegacy.IfcWriter.addExtrudedCircle(), importIFClegacy.IfcWriter.addExtrudedCompositeCurve(), importIFClegacy.IfcWriter.addExtrudedEllipse(), and importIFClegacy.IfcWriter.addExtrudedPolyline().

◆ addExtrudedCircle()

def importIFClegacy.IfcWriter.addExtrudedCircle (   self,
  data,
  extrusion,
  placement = None,
  color = None 
)
addExtrudedCircle(data,extrusion,[placement,color]): makes an extruded circle
from the given data (center,radius) and the given extrusion vector

References Base::InventorBuilder.addColor(), importIFClegacy.IfcWriter.addColor(), importIFClegacy.IfcWriter.addExtrusion(), importIFClegacy.IfcWriter.addPlacement(), and importIFClegacy.IfcWriter.addProfile().

◆ addExtrudedCompositeCurve()

def importIFClegacy.IfcWriter.addExtrudedCompositeCurve (   self,
  curves,
  extrusion,
  placement = None,
  color = None 
)
addExtrudedCompositeCurve(curves,extrusion,[placement,color]): makes an extruded polyline
from the given curves and the given extrusion vector

References Base::InventorBuilder.addColor(), importIFClegacy.IfcWriter.addColor(), importIFClegacy.IfcWriter.addExtrusion(), importIFClegacy.IfcWriter.addPlacement(), and importIFClegacy.IfcWriter.addProfile().

◆ addExtrudedEllipse()

def importIFClegacy.IfcWriter.addExtrudedEllipse (   self,
  data,
  extrusion,
  placement = None,
  color = None 
)
addExtrudedEllipse(data,extrusion,[placement,color]): makes an extruded ellipse
from the given data (center,radiusx,radiusy) and the given extrusion vector

References Base::InventorBuilder.addColor(), importIFClegacy.IfcWriter.addColor(), importIFClegacy.IfcWriter.addExtrusion(), importIFClegacy.IfcWriter.addPlacement(), and importIFClegacy.IfcWriter.addProfile().

◆ addExtrudedPolyline()

def importIFClegacy.IfcWriter.addExtrudedPolyline (   self,
  points,
  extrusion,
  placement = None,
  color = None 
)
addExtrudedPolyline(points,extrusion,[placement,color]): makes an extruded polyline
from the given points and the given extrusion vector

References Base::InventorBuilder.addColor(), importIFClegacy.IfcWriter.addColor(), importIFClegacy.IfcWriter.addExtrusion(), importIFClegacy.IfcWriter.addPlacement(), and importIFClegacy.IfcWriter.addProfile().

◆ addExtrusion()

def importIFClegacy.IfcWriter.addExtrusion (   self,
  profile,
  extrusion,
  placement = None 
)
addExtrusion(profile,extrusion,[placement]): makes an
extrusion of the given polyline with the given extrusion vector

References importIFClegacy.IfcWriter._fileobject, importIFClegacy.IfcWriter.addPlacement(), importIFClegacy.create(), and importIFClegacy.getValueAndDirection().

Referenced by importIFClegacy.IfcWriter.addExtrudedCircle(), importIFClegacy.IfcWriter.addExtrudedCompositeCurve(), importIFClegacy.IfcWriter.addExtrudedEllipse(), and importIFClegacy.IfcWriter.addExtrudedPolyline().

◆ addFace()

def importIFClegacy.IfcWriter.addFace (   self,
  face 
)
addFace(face): creates a face from the given face data (a list of lists of points).
The first is the outer wire, the next are optional inner wires. They must be reversed in order

References importIFClegacy.IfcWriter._fileobject, importIFClegacy.create(), importIFClegacy.IfcWriter.fpoints, importIFClegacy.IfcWriter.frefs, and importIFClegacy.getTuple().

◆ addFacetedBrep()

def importIFClegacy.IfcWriter.addFacetedBrep (   self,
  faces,
  color = None 
)
addFacetedBrep(self,faces,[color]): creates a faceted brep object from the given list
of faces (each face is a list of lists of points, inner wires are reversed)

◆ addGroup()

def importIFClegacy.IfcWriter.addGroup (   self,
  entities,
  name = "Default group",
  description = None 
)
addGroup(entities,[name,description]): adds a group with the given entities

References importIFClegacy.IfcWriter._fileobject, importIFClegacy.IfcWriter._owner, Image::ImageBase._owner, ifc2x3.ifcasset._owner, ifc4.ifcasset._owner, importIFClegacy.IfcWriter._storeyRelations, importIFClegacy.create(), and importIFClegacy.uid().

◆ addPlacement()

def importIFClegacy.IfcWriter.addPlacement (   self,
  reference = None,
  origin = (0,0,0),
  xaxis = (1,0,0),
  zaxis = (0,0,1),
  local = True,
  flat = False 
)

◆ addProduct()

def importIFClegacy.IfcWriter.addProduct (   self,
  elttype,
  shapes,
  storey = None,
  placement = None,
  name = "Unnamed element",
  description = None,
  extra = None 
)
addProduct(elttype,representations,[storey,placement,name,description,extra]): creates an element of the given type
(IfcWall, IfcBeam, etc...) with the given attributes, plus the given extra attributes.

References importIFClegacy.IfcWriter._fileobject, importIFClegacy.IfcWriter._owner, Image::ImageBase._owner, ifc2x3.ifcasset._owner, ifc4.ifcasset._owner, importIFClegacy.IfcWriter._relate(), importIFClegacy.IfcWriter.addPlacement(), importIFClegacy.IfcWriter.addRepresentations(), importIFClegacy.IfcWriter.addStorey(), importIFClegacy.IfcWriter.BuildingProducts, importIFClegacy.create(), importIFClegacy.getPropertyNames(), importIFClegacy.IfcWriter.Storeys, and importIFClegacy.uid().

◆ addProfile()

def importIFClegacy.IfcWriter.addProfile (   self,
  ifctype,
  data,
  curvetype = "AREA" 
)
addProfile(ifctype,data): creates a 2D profile of the given type, with the given
data as arguments, which must be formatted correctly according to the type.

References importIFClegacy.IfcWriter._fileobject, importIFClegacy.IfcWriter.addPlacement(), importIFClegacy.create(), and importIFClegacy.getTuple().

Referenced by importIFClegacy.IfcWriter.addExtrudedCircle(), importIFClegacy.IfcWriter.addExtrudedCompositeCurve(), importIFClegacy.IfcWriter.addExtrudedEllipse(), and importIFClegacy.IfcWriter.addExtrudedPolyline().

◆ addRepresentations()

def importIFClegacy.IfcWriter.addRepresentations (   self,
  shapes 
)
addRepresentations(shapes,[solidType]): creates a representation from the given shape

References importIFClegacy.IfcWriter._fileobject, importIFClegacy.IfcWriter._repcontext, and importIFClegacy.create().

Referenced by importIFClegacy.IfcWriter.addProduct().

◆ addSite()

def importIFClegacy.IfcWriter.addSite (   self,
  placement = None,
  name = "Site",
  description = None,
  latitude = None,
  longitude = None,
  elevation = None,
  landtitlenumber = None,
  address = None 
)
makeSite(ifcdoc,project,owner,[placement,name,description]): creates a site
in the given ifc document

References importIFClegacy.IfcWriter._fileobject, importIFClegacy.IfcWriter._owner, Image::ImageBase._owner, ifc2x3.ifcasset._owner, ifc4.ifcasset._owner, importIFClegacy.IfcWriter._relate(), importIFClegacy.IfcWriter.addPlacement(), importIFClegacy.create(), importIFClegacy.IfcWriter.Project, importIFClegacy.IfcWriter.Site, and importIFClegacy.uid().

Referenced by importIFClegacy.IfcWriter.addBuilding().

◆ addStorey()

def importIFClegacy.IfcWriter.addStorey (   self,
  building = None,
  placement = None,
  name = "Default storey",
  description = None 
)
addStorey([building,placement,name,description]): adds a storey

References importIFClegacy.IfcWriter._fileobject, importIFClegacy.IfcWriter._owner, Image::ImageBase._owner, ifc2x3.ifcasset._owner, ifc4.ifcasset._owner, importIFClegacy.IfcWriter._relate(), importIFClegacy.IfcWriter.addBuilding(), importIFClegacy.IfcWriter.addPlacement(), importIFClegacy.IfcWriter.Buildings, importIFClegacy.create(), importIFClegacy.IfcWriter.Storeys, and importIFClegacy.uid().

Referenced by importIFClegacy.IfcWriter.addProduct().

◆ findByName()

def importIFClegacy.IfcWriter.findByName (   self,
  ifctype,
  name 
)

References importIFClegacy.IfcWriter._fileobject.

◆ union()

def importIFClegacy.IfcWriter.union (   self,
  solids 
)
union(solids): creates a boolean union between all the solids of the list

References importIFClegacy.IfcWriter._fileobject, and importIFClegacy.create().

◆ write()

def importIFClegacy.IfcWriter.write (   self,
  fp = None 
)

References importIFClegacy.IfcWriter._fileobject, importIFClegacy.IfcWriter._fix(), importIFClegacy.IfcWriter.FilePath, zipios::FilePath.FilePath(), importIFClegacy.pyopen, and importIFClegacy.IfcWriter.write().

Referenced by gzip_utf8.GzipFile.seek(), and importIFClegacy.IfcWriter.write().

Member Data Documentation

◆ BuildingProducts

importIFClegacy.IfcWriter.BuildingProducts

◆ Buildings

importIFClegacy.IfcWriter.Buildings

◆ FilePath

importIFClegacy.IfcWriter.FilePath

◆ fpoints

importIFClegacy.IfcWriter.fpoints

◆ frefs

importIFClegacy.IfcWriter.frefs

◆ Name

importIFClegacy.IfcWriter.Name

◆ Organization

importIFClegacy.IfcWriter.Organization

◆ Owner

importIFClegacy.IfcWriter.Owner

◆ Project

importIFClegacy.IfcWriter.Project

◆ Site

importIFClegacy.IfcWriter.Site

◆ Storeys

importIFClegacy.IfcWriter.Storeys

The documentation for this class was generated from the following file: