femsolver.settings Namespace Reference

Classes

class  DirSetting
 

Functions

def get_binary (name)
 
def get_custom_dir ()
 
def get_dir_setting ()
 
def get_write_comments (name)
 

Function Documentation

◆ get_binary()

def femsolver.settings.get_binary (   name)
 Find binary of solver *name* honoring user settings.

Return the specific path set by the user in FreeCADs settings/parameter
system if set or the default binary name if no specific path is set. If no
path was found because the solver *name* is not supported ``None`` is
returned. This method does not check whether the binary actually exists
and is callable.

:param name: solver id as a ``str`` (see :mod:`femsolver.settings`)

References femsolver.settings.get_binary().

Referenced by femsolver.settings.get_binary().

◆ get_custom_dir()

def femsolver.settings.get_custom_dir ( )
 Get value for :term:`General/CustomDirectoryPath` parameter. 

◆ get_dir_setting()

def femsolver.settings.get_dir_setting ( )
 Return directory setting set by the user.

Return one of the three possible values of the :class:`DirSetting` enum
depending on the setting set in FreeCAD parameter system. Result dependes
on the values of :term:`General/UseTempDirectory`,
:term:`General/UseBesideDirectory` and :term:`General/UseCustomDirectory`.

◆ get_write_comments()

def femsolver.settings.get_write_comments (   name)
 Check whether "write_comments" is set for solver.

Returns ``True`` if the "write_comments" setting/parameter is set for the
solver with the id *name*. Returns ``False`` otherwise. If the solver is
not supported ``None`` is returned.

:param name: solver id as a ``str`` (see :mod:`femsolver.settings`)

References femsolver.settings.get_write_comments().

Referenced by femsolver.settings.get_write_comments().