PyFoam.Basics.STLFile module

Read a STL file and do simple manipulations

class PyFoam.Basics.STLFile.STLFile(fName=None)[source]

Bases: object

Store a complete STL-file and do simple manipulations with it

__dict__ = mappingproxy({'__module__': 'PyFoam.Basics.STLFile', '__doc__': 'Store a complete STL-file and do simple manipulations with it', 'noName': '<no name given>', '__init__': <function STLFile.__init__>, 'resetInfo': <function STLFile.resetInfo>, 'filename': <function STLFile.filename>, 'expectedToken': <function STLFile.expectedToken>, 'erasePatches': <function STLFile.erasePatches>, 'mergePatches': <function STLFile.mergePatches>, 'patchInfo': <function STLFile.patchInfo>, 'writeTo': <function STLFile.writeTo>, '__iter__': <function STLFile.__iter__>, '__iadd__': <function STLFile.__iadd__>, '__dict__': <attribute '__dict__' of 'STLFile' objects>, '__weakref__': <attribute '__weakref__' of 'STLFile' objects>})
__iadd__(other)[source]
__init__(fName=None)[source]
Parameters

fName – filename of the STL-file. If None then an empty file is created

__iter__()[source]
__module__ = 'PyFoam.Basics.STLFile'
__weakref__

list of weak references to the object (if defined)

erasePatches(patchNames)[source]

Erase the patches in the list

expectedToken(l, token, i)[source]
filename()[source]

The filename (without the full patch)

mergePatches(patchNames, targetPatchName)[source]

Merge the patches in the list and put them into a new patch

noName = '<no name given>'
patchInfo()[source]

Get info about the patches. A list of dictionaries with the relevant information

resetInfo()[source]

Set cached info to nothing

writeTo(fName)[source]

Write to a file