# Path: pycdlib/pycdlibexception.py
# class PyCdlibException(Exception):
# class PyCdlibInternalError(PyCdlibException):
# class PyCdlibInvalidInput(PyCdlibException):
# class PyCdlibInvalidISO(PyCdlibException):
#     def __init__(self, msg):
#     def __init__(self, msg):
#     def __init__(self, msg):
#     def __init__(self, msg):
# 
# Path: pycdlib/utils.py
# def swab_32bit(x):
# def swab_16bit(x):
# def ceiling_div(numer, denom):
# def copy_data(data_length, blocksize, infp, outfp):
# def encode_space_pad(instr, length, encoding):
# def normpath(path):
# def gmtoffset_from_tm(tm, local):
# def zero_pad(fp, data_size, pad_size):
# def starts_with_slash(path):
# def split_path(iso_path):
# def file_object_supports_binary(fp):
# def truncate_basename(basename, iso_level, is_dir):
# def mangle_file_for_iso9660(orig, iso_level):
# def mangle_dir_for_iso9660(orig, iso_level):
#     def __init__(self, target):
#     def __enter__(self):
#     def __exit__(self, *_, **__):
#     def __len__(self):
#     def dispose(self):
#     def get_target(self):
#     def get_handle(self):
#     def get_geometry(self):
#     def tell(self):
#     def _tell(self):
#     def seek(self, offset, whence=os.SEEK_SET):
#     def read(self, size=-1):
#     def align(self, size, to=None):
# class Win32RawDevice:


import struct
from pycdlib import pycdlibexception
from pycdlib import utils
    from typing import Type  # NOQA pylint: disable=unused-import

    def _new(self, name, parent_dir_num):
        # type: (bytes, int) -> None
        """
        An internal method to create a new Path Table Record.

        Parameters:
         name - The name for this Path Table Record.
         parent_dir_num - The directory number of the parent of this Path Table
                          Record.
        Returns:
         Nothing.
        """
        self.len_di = len(name)
        self.xattr_length = 0  # FIXME: we don't support xattr for now
        self.parent_directory_num = parent_dir_num
        self.directory_identifier = name
        self._initialized = True

    def new_root(self):
        # type: () -> None
        """
        Create a new root Path Table Record.

        Parameters:
         None.
        Returns:
         Nothing.
        """
        if self._initialized:

# Path: pycdlib/pycdlibexception.py
# class PyCdlibException(Exception):
# class PyCdlibInternalError(PyCdlibException):
# class PyCdlibInvalidInput(PyCdlibException):
# class PyCdlibInvalidISO(PyCdlibException):
#     def __init__(self, msg):
#     def __init__(self, msg):
#     def __init__(self, msg):
#     def __init__(self, msg):
# 
# Path: pycdlib/utils.py
# def swab_32bit(x):
# def swab_16bit(x):
# def ceiling_div(numer, denom):
# def copy_data(data_length, blocksize, infp, outfp):
# def encode_space_pad(instr, length, encoding):
# def normpath(path):
# def gmtoffset_from_tm(tm, local):
# def zero_pad(fp, data_size, pad_size):
# def starts_with_slash(path):
# def split_path(iso_path):
# def file_object_supports_binary(fp):
# def truncate_basename(basename, iso_level, is_dir):
# def mangle_file_for_iso9660(orig, iso_level):
# def mangle_dir_for_iso9660(orig, iso_level):
#     def __init__(self, target):
#     def __enter__(self):
#     def __exit__(self, *_, **__):
#     def __len__(self):
#     def dispose(self):
#     def get_target(self):
#     def get_handle(self):
#     def get_geometry(self):
#     def tell(self):
#     def _tell(self):
#     def seek(self, offset, whence=os.SEEK_SET):
#     def read(self, size=-1):
#     def align(self, size, to=None):
# class Win32RawDevice:


# Path: pycdlib/path_table_record.py
import struct
from pycdlib import pycdlibexception
from pycdlib import utils
    from typing import Type  # NOQA pylint: disable=unused-import


    def _new(self, name, parent_dir_num):
        # type: (bytes, int) -> None
        """
        An internal method to create a new Path Table Record.

        Parameters:
         name - The name for this Path Table Record.
         parent_dir_num - The directory number of the parent of this Path Table
                          Record.
        Returns:
         Nothing.
        """
        self.len_di = len(name)
        self.xattr_length = 0  # FIXME: we don't support xattr for now
        self.parent_directory_num = parent_dir_num
        self.directory_identifier = name
        self._initialized = True

    def new_root(self):
        # type: () -> None
        """
        Create a new root Path Table Record.

        Parameters:
         None.
        Returns:
         Nothing.
        """
        if self._initialized:

            raise pycdlibexception.PyCdlibInternalError('Path Table Record already initialized')