Uranium
Application Framework
 All Classes Namespaces Files Functions Variables Pages
UM.FileHandler.FileHandler.FileHandler Class Reference

Central class for reading and writing meshes. More...

Inheritance diagram for UM.FileHandler.FileHandler.FileHandler:
UM.Mesh.MeshFileHandler.MeshFileHandler UM.Workspace.WorkspaceFileHandler.WorkspaceFileHandler

Public Member Functions

def __init__
 
def setApplication
 
def getApplication
 
def getInstance
 Return the singleton instance of the filehandler. More...
 
def supportedReadFileTypes
 
def supportedWriteFileTypes
 
def readLocalFile
 
def getSupportedFileTypesWrite
 Get list of all supported filetypes for writing. More...
 
def getSupportedFileTypesRead
 
def addReader
 
def addWriter
 
def readerRead
 
def getWriterByMimeType
 Get a mesh writer object that supports writing the specified mime type. More...
 
def getWriter
 Get an instance of a mesh writer by ID.
 
def getReaderForFile
 Find a Reader that accepts the given file name. More...
 

Detailed Description

Central class for reading and writing meshes.

This class is created by Application and handles reading and writing mesh files.

Member Function Documentation

def UM.FileHandler.FileHandler.FileHandler.getInstance (   cls,
  args,
  kwargs 
)

Return the singleton instance of the filehandler.

def UM.FileHandler.FileHandler.FileHandler.getReaderForFile (   self,
  file_name 
)

Find a Reader that accepts the given file name.

Parameters
file_nameThe name of file to load.
Returns
Reader that accepts the given file name. If no acceptable Reader is found None is returned.
def UM.FileHandler.FileHandler.FileHandler.getSupportedFileTypesWrite (   self)

Get list of all supported filetypes for writing.

Returns
List of dicts containing id, extension, description and mime_type for all supported file types.
def UM.FileHandler.FileHandler.FileHandler.getWriterByMimeType (   self,
  mime 
)

Get a mesh writer object that supports writing the specified mime type.

Parameters
mimeThe mime type that should be supported.
Returns
A MeshWriter instance or None if no mesh writer supports the specified mime type. If there are multiple writers that support the specified mime type, the first entry is returned.

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