Skip to content

NemAll_Python_Utility

Exposed utility classes and functions

CheckModuleLicence

CheckModuleLicence(moduleNumber: int) -> bool

Check for a module licence

Parameters:

  • moduleNumber (int) –

    Number of the module

Returns:

  • bool

    Licence for the module available: True/False

ClearUnitTestDocument

ClearUnitTestDocument()

Clear the document

EncryptString

EncryptString(stringtoEncrypt: str, pypName: str) -> str

ImportScript an encrypted PythonPart script

Parameters:

  • stringtoEncrypt (str) –

    Path of the file

  • pypName (str) –

    Name of the PythonPart

GetPluginNameHash

GetPluginNameHash() -> int

ImportScript

ImportScript(script: str, global_dict: object, pypName: str)

ImportScript an encrypted PythonPart script

Parameters:

  • script (str) –

    Path of the file

  • global_dict (object) –

    File name

  • pypName (str) –

    Name of the PythonPart

InitReinfNormInterpreter

InitReinfNormInterpreter()

InitUnitTest

InitUnitTest(loadResources: bool) -> DocumentAdapter

Initialize the unit test

Parameters:

  • loadResources (bool) –

    Load the resources

IsExecutedByUnitTest

IsExecutedByUnitTest() -> bool

Check, whether the script is executed by a unit test

Returns:

  • bool

    Script is executed by a unit test: True/False

LoadSymbolForUnitTest

LoadSymbolForUnitTest(
    file: str, clearDocument: bool, updateArchEleGeometry: bool = False
) -> BaseElementAdapterList

Load a symbol to the Array

Parameters:

  • file (str) –

    File name

  • clearDocument (bool) –

    Clear the document before symbol loading

  • updateArchEleGeometry (bool, default: False ) –

    Update the geometry elements after load (e.g. adapts slabs to the planes

Returns:

ShowMessageBox

ShowMessageBox(text: str, flags: int, dontAsk: int = 0) -> int

Displays Message Box

Parameters:

  • text (str) –

    Message box text

  • flags (int) –

    Button flags dontAsk text number for the text that will be displayed when MB_DONOTASKAGAIN is used

Placeholder