from_str#

classmethod OptislangPathType.from_str(string: str) OptislangPathType#

Convert a string to an instance of the OptislangPathType class.

Parameters:
string: str

String that shall be converted.

Returns:
OptislangPathType

Instance of the OptislangPathType class.

Raises:
TypeError

Raised when invalid type of string was given.

ValueError

Raised when invalid value of string was given.