Skip to content

ProjectService

Canonical path: NemAll_Python_BaseElements.ProjectService

Utility for processing the Allplan project

This utility class provides methods for processing the Allplan project, such as switching between projects or getting the project path.

CloseAllplan staticmethod

CloseAllplan()

Close Allplan

GetCurrentProjectNameAndHost staticmethod

GetCurrentProjectNameAndHost() -> tuple

Get the project and host name

Returns:

  • tuple

    tuple(project name, host name)

GetCurrentUserAsBwsPath staticmethod

GetCurrentUserAsBwsPath() -> str

Get the current user as BWS path

Returns:

  • str

    User as BWS path

GetProjectPath staticmethod

GetProjectPath(projectName: str, hostName: str) -> tuple

Get the project path

Parameters:

  • hostName (str) –

    Host name

  • projectName (str) –

    Project name

Returns:

  • tuple

    tuple(Error, project path)

OpenProject staticmethod

OpenProject(hostName: DocumentAdapter, projectName: str, doc: str) -> str

Open the project

Parameters:

  • doc (str) –

    Document

  • hostName (DocumentAdapter) –

    Host name

  • projectName (str) –

    Project name

Returns:

  • str

    String with the result the attempt to open the project. Possible results are:

    • Active project
    • Project not exist
    • Not possible to open the project
    • Project opened
Placeholder