List the children entities of the directory.

        Raises exception if the object is a file.

        :return:

def ls(self):
        """List the children entities of the directory.

        Raises exception if the object is a file.

        :return:
        """
        if self.isfile():
            raise NotDirectoryError('Cannot ls() on non-directory node: {path}'.format(path=self._pyerarchy_path))

        return os.listdir(self._pyerarchy_path)