def get_path(self, appendix=None, by_name=False):
        """ Recursively create the path of the state.

        The path is generated in bottom up method i.e. from the nested child states to the root state. The method
        concatenates either State.state_id (always unique) or State.name (maybe not unique but human readable) as
        state identifier for the path.

        :param str appendix: the part of the path that was already calculated by previous function calls
        :param bool by_name: The boolean enables name usage to generate the path
        :rtype: str
        :return: the full path to the root state
        """
        if by_name:
            state_identifier = self.name
        else:
            state_identifier = self.state_id

        if not self.is_root_state:
            if appendix is None:
                return self.parent.get_path(state_identifier, by_name)
            else:
                return self.parent.get_path(state_identifier + PATH_SEPARATOR + appendix, by_name)
        else:
            if appendix is None:
                return state_identifier
            else:
                return state_identifier + PATH_SEPARATOR + appendix
def get_path ( self , appendix = None , by_name = False ) : if by_name : state_identifier = self . name else : state_identifier = self . state_id if not self . is_root_state : if appendix is None : return self . parent . get_path ( state_identifier , by_name ) else : return self . parent . get_path ( state_identifier + PATH_SEPARATOR + appendix , by_name ) else : if appendix is None : return state_identifier else : return state_identifier + PATH_SEPARATOR + appendix
Recursively create the path of the state.

        The path is generated in bottom up method i.e. from the nested child states to the root state. The method
        concatenates either State.state_id (always unique) or State.name (maybe not unique but human readable) as
        state identifier for the path.

        :param str appendix: the part of the path that was already calculated by previous function calls
        :param bool by_name: The boolean enables name usage to generate the path
        :rtype: str
        :return: the full path to the root state