# This file was automatically generated by SWIG (http://www.swig.org). # Version 1.3.31 # # Don't modify this file, modify the SWIG interface instead. # This file is compatible with both classic and new-style classes. """ This is a wrapper for The CD Input and Control library's ISO-9660 library See also the ISO-9660 specification. The freely available European equivalant standard is called ECMA-119. """ import _pyiso9660 import new new_instancemethod = new.instancemethod try: _swig_property = property except NameError: pass # Python < 2.2 doesn't have 'property'. def _swig_setattr_nondynamic(self,class_type,name,value,static=1): if (name == "thisown"): return self.this.own(value) if (name == "this"): if type(value).__name__ == 'PySwigObject': self.__dict__[name] = value return method = class_type.__swig_setmethods__.get(name,None) if method: return method(self,value) if (not static) or hasattr(self,name): self.__dict__[name] = value else: raise AttributeError("You cannot add attributes to %s" % self) def _swig_setattr(self,class_type,name,value): return _swig_setattr_nondynamic(self,class_type,name,value,0) def _swig_getattr(self,class_type,name): if (name == "thisown"): return self.this.own() method = class_type.__swig_getmethods__.get(name,None) if method: return method(self) raise AttributeError,name def _swig_repr(self): try: strthis = "proxy of " + self.this.__repr__() except: strthis = "" return "<%s.%s; %s >" % (self.__class__.__module__, self.__class__.__name__, strthis,) import types try: _object = types.ObjectType _newclass = 1 except AttributeError: class _object : pass _newclass = 0 del types VERSION_NUM = _pyiso9660.VERSION_NUM INVALID_LBA = _pyiso9660.INVALID_LBA INVALID_LSN = _pyiso9660.INVALID_LSN CD_FRAMESIZE = _pyiso9660.CD_FRAMESIZE CD_FRAMESIZE_RAW = _pyiso9660.CD_FRAMESIZE_RAW ISO_BLOCKSIZE = _pyiso9660.ISO_BLOCKSIZE M2F2_SECTOR_SIZE = _pyiso9660.M2F2_SECTOR_SIZE M2RAW_SECTOR_SIZE = _pyiso9660.M2RAW_SECTOR_SIZE CDIO_READ_MODE_AUDIO = _pyiso9660.CDIO_READ_MODE_AUDIO CDIO_READ_MODE_M1F1 = _pyiso9660.CDIO_READ_MODE_M1F1 CDIO_READ_MODE_M1F2 = _pyiso9660.CDIO_READ_MODE_M1F2 CDIO_READ_MODE_M2F1 = _pyiso9660.CDIO_READ_MODE_M2F1 CDIO_READ_MODE_M2F2 = _pyiso9660.CDIO_READ_MODE_M2F2 cdio_read_sectors = _pyiso9660.cdio_read_sectors cdio_eject_media_drive = _pyiso9660.cdio_eject_media_drive PVD_SECTOR = _pyiso9660.PVD_SECTOR EVD_SECTOR = _pyiso9660.EVD_SECTOR LEN_ISONAME = _pyiso9660.LEN_ISONAME MAX_SYSTEM_ID = _pyiso9660.MAX_SYSTEM_ID MAX_ISONAME = _pyiso9660.MAX_ISONAME MAX_PREPARER_ID = _pyiso9660.MAX_PREPARER_ID MAX_ISOPATHNAME = _pyiso9660.MAX_ISOPATHNAME FILE = _pyiso9660.FILE EXISTENCE = _pyiso9660.EXISTENCE DIRECTORY = _pyiso9660.DIRECTORY ASSOCIATED = _pyiso9660.ASSOCIATED RECORD = _pyiso9660.RECORD PROTECTION = _pyiso9660.PROTECTION DRESERVED1 = _pyiso9660.DRESERVED1 DRESERVED2 = _pyiso9660.DRESERVED2 MULTIEXTENT = _pyiso9660.MULTIEXTENT VD_BOOT_RECORD = _pyiso9660.VD_BOOT_RECORD VD_PRIMARY = _pyiso9660.VD_PRIMARY VD_SUPPLEMENTARY = _pyiso9660.VD_SUPPLEMENTARY VD_PARITION = _pyiso9660.VD_PARITION VD_END = _pyiso9660.VD_END MAX_PUBLISHER_ID = _pyiso9660.MAX_PUBLISHER_ID MAX_APPLICATION_ID = _pyiso9660.MAX_APPLICATION_ID MAX_VOLUME_ID = _pyiso9660.MAX_VOLUME_ID MAX_VOLUMESET_ID = _pyiso9660.MAX_VOLUMESET_ID STANDARD_ID = _pyiso9660.STANDARD_ID NOCHECK = _pyiso9660.NOCHECK SEVEN_BIT = _pyiso9660.SEVEN_BIT ACHARS = _pyiso9660.ACHARS DCHARS = _pyiso9660.DCHARS EXTENSION_JOLIET_LEVEL1 = _pyiso9660.EXTENSION_JOLIET_LEVEL1 EXTENSION_JOLIET_LEVEL2 = _pyiso9660.EXTENSION_JOLIET_LEVEL2 EXTENSION_JOLIET_LEVEL3 = _pyiso9660.EXTENSION_JOLIET_LEVEL3 EXTENSION_ROCK_RIDGE = _pyiso9660.EXTENSION_ROCK_RIDGE EXTENSION_HIGH_SIERRA = _pyiso9660.EXTENSION_HIGH_SIERRA EXTENSION_ALL = _pyiso9660.EXTENSION_ALL EXTENSION_NONE = _pyiso9660.EXTENSION_NONE EXTENSION_JOLIET = _pyiso9660.EXTENSION_JOLIET def open_iso(*args): """ open_iso(path) Open an ISO 9660 image for reading. Maybe in the future we will have mode. None is returned on error. """ return _pyiso9660.open_iso(*args) def open_ext(*args): """ Open an ISO 9660 image for reading allowing various ISO 9660 extensions. Maybe in the future we will have a mode. None is returned on error. """ return _pyiso9660.open_ext(*args) def open_fuzzy(*args): """ Open an ISO 9660 image for reading with some tolerence for positioning of the ISO9660 image. We scan for ISO_STANDARD_ID and use that to set the eventual offset to adjust by (as long as that is <= i_fuzz). Maybe in the future we will have a mode. None is returned on error. see iso9660_open """ return _pyiso9660.open_fuzzy(*args) def iso9660_open_fuzzy_ext(*args): """ Open an ISO 9660 image for reading with some tolerence for positioning of the ISO9660 image. We scan for ISO_STANDARD_ID and use that to set the eventual offset to adjust by (as long as that is <= i_fuzz). Maybe in the future we will have a mode. None is returned on error. see open_iso """ return _pyiso9660.iso9660_open_fuzzy_ext(*args) def ifs_fuzzy_read_superblock(*args): """ Read the Super block of an ISO 9660 image but determine framesize and datastart and a possible additional offset. Generally here we are not reading an ISO 9660 image but a CD-Image which contains an ISO 9660 filesystem. """ return _pyiso9660.ifs_fuzzy_read_superblock(*args) def close(*args): """ Close previously opened ISO 9660 image. True is unconditionally returned. If there was an error false would be returned. """ return _pyiso9660.close(*args) def seek_read(*args): """ Seek to a position and then read n bytes. (buffer, size) are returned. """ return _pyiso9660.seek_read(*args) def fs_read_pvd(*args): """ Read the Primary Volume Descriptor for a CD. None is returned if there was an error. """ return _pyiso9660.fs_read_pvd(*args) def ifs_read_pvd(*args): """ Read the Primary Volume Descriptor for an ISO 9660 image. None is returned if there was an error. """ return _pyiso9660.ifs_read_pvd(*args) def fs_read_superblock(*args): """ Read the Super block of an ISO 9660 image. This is the Primary Volume Descriptor (PVD) and perhaps a Supplemental Volume Descriptor if (Joliet) extensions are acceptable. """ return _pyiso9660.fs_read_superblock(*args) def ifs_read_superblock(*args): """ Read the Super block of an ISO 9660 image. This is the Primary Volume Descriptor (PVD) and perhaps a Supplemental Volume Descriptor if (Joliet) extensions are acceptable. """ return _pyiso9660.ifs_read_superblock(*args) def set_dtime(*args): """Set time in format used in ISO 9660 directory index record""" return _pyiso9660.set_dtime(*args) def set_ltime(*args): """Set 'long' time in format used in ISO 9660 primary volume descriptor""" return _pyiso9660.set_ltime(*args) def get_dtime(*args): """ Get Unix time structure from format use in an ISO 9660 directory index record. Even though tm_wday and tm_yday fields are not explicitly in idr_date, they are calculated from the other fields. If tm is to reflect the localtime, set 'use_localtime' true, otherwise tm will reported in GMT. """ return _pyiso9660.get_dtime(*args) def get_ltime(*args): """ Get 'long' time in format used in ISO 9660 primary volume descriptor from a Unix time structure. """ return _pyiso9660.get_ltime(*args) def is_dchar(*args): """ Return true if c is a DCHAR - a character that can appear in an an ISO-9600 level 1 directory name. These are the ASCII capital letters A-Z, the digits 0-9 and an underscore. """ return _pyiso9660.is_dchar(*args) def is_achar(*args): """ Return true if c is an ACHAR - These are the DCHAR's plus some ASCII symbols including the space symbol. """ return _pyiso9660.is_achar(*args) def name_translate(*args): """ Convert an ISO-9660 file name that stored in a directory entry into what's usually listed as the file name in a listing. Lowercase name, and remove trailing ;1's or .;1's and turn the other ;'s into version numbers. @param psz_oldname the ISO-9660 filename to be translated. @param psz_newname returned string. The caller allocates this and it should be at least the size of psz_oldname. @return length of the translated string is returned. """ return _pyiso9660.name_translate(*args) def name_translate_ext(*args): """ Convert an ISO-9660 file name that stored in a directory entry into what's usually listed as the file name in a listing. Lowercase name if no Joliet Extension interpretation. Remove trailing ;1's or .;1's and turn the other ;'s into version numbers. @param psz_oldname the ISO-9660 filename to be translated. @param psz_newname returned string. The caller allocates this and it should be at least the size of psz_oldname. @param i_joliet_level 0 if not using Joliet Extension. Otherwise the Joliet level. @return length of the translated string is returned. It will be no greater than the length of psz_oldname. """ return _pyiso9660.name_translate_ext(*args) def strncpy_pad(*args): """ Pad string src with spaces to size len and copy this to dst. If en is less than the length of src, dst will be truncated to the first len characters of src. src can also be scanned to see if it contains only ACHARs, DCHARs, 7-bit ASCII chars depending on the enumeration _check. In addition to getting changed, dst is the return value. Note: this string might not be NULL terminated. """ return _pyiso9660.strncpy_pad(*args) def dirname_valid_p(*args): """ Check that psz_path is a valid ISO-9660 directory name. A valid directory name should not start out with a slash (/), dot (.) or null byte, should be less than 37 characters long, have no more than 8 characters in a directory component which is separated by a /, and consist of only DCHARs. True is returned if psz_path is valid. """ return _pyiso9660.dirname_valid_p(*args) def pathname_isofy(*args): """ Take psz_path and a version number and turn that into a ISO-9660 pathname. (That's just the pathname followed by ';' and the version number. For example, mydir/file.ext -> MYDIR/FILE.EXT;1 for version 1. The resulting ISO-9660 pathname is returned. """ return _pyiso9660.pathname_isofy(*args) def pathname_valid_p(*args): """ Check that psz_path is a valid ISO-9660 pathname. A valid pathname contains a valid directory name, if one appears and the filename portion should be no more than 8 characters for the file prefix and 3 characters in the extension (or portion after a dot). There should be exactly one dot somewhere in the filename portion and the filename should be composed of only DCHARs. True is returned if psz_path is valid. """ return _pyiso9660.pathname_valid_p(*args) def fs_stat(*args): """Return file status for psz_path. None is returned on error.""" return _pyiso9660.fs_stat(*args) def fs_stat_translate(*args): """ Return file status for path name psz_path. None is returned on error. pathname version numbers in the ISO 9660 name are dropped, i.e. ;1 is removed and if level 1 ISO-9660 names are lowercased. The b_mode2 parameter is not used. """ return _pyiso9660.fs_stat_translate(*args) def ifs_stat(*args): """Return file status for pathname. None is returned on error.""" return _pyiso9660.ifs_stat(*args) def ifs_stat_translate(*args): """ Return file status for path name psz_path. undef is returned on error. pathname version numbers in the ISO 9660 name are dropped, i.e. ;1 is removed and if level 1 ISO-9660 names are lowercased. """ return _pyiso9660.ifs_stat_translate(*args) def fs_readdir(*args): """ Read psz_path (a directory) and return a list of iso9660_stat_t pointers for the files inside that directory. """ return _pyiso9660.fs_readdir(*args) def ifs_readdir(*args): """ Read psz_path (a directory) and return a list of iso9660_stat_t pointers for the files inside that directory. """ return _pyiso9660.ifs_readdir(*args) def get_application_id(*args): """ Return the PVD's application ID. None is returned if there is some problem in getting this. """ return _pyiso9660.get_application_id(*args) def ifs_get_application_id(*args): """ Get the application ID. Return None if there is some problem in getting this. """ return _pyiso9660.ifs_get_application_id(*args) def get_joliet_level(*args): """Return the Joliet level recognized for p_iso.""" return _pyiso9660.get_joliet_level(*args) def get_dir_len(*args): """Return the Joliet level recognized for p_iso.""" return _pyiso9660.get_dir_len(*args) def iso9660_dir_to_name(*args): """Return the directory name stored in the iso9660_dir_t.""" return _pyiso9660.iso9660_dir_to_name(*args) def get_preparer_id(*args): """ Return a string containing the preparer id with trailing blanks removed. """ return _pyiso9660.get_preparer_id(*args) def ifs_get_preparer_id(*args): """ Get the preparer ID. Return None if there is some problem in getting this. """ return _pyiso9660.ifs_get_preparer_id(*args) def get_publisher_id(*args): """ Return a string containing the PVD's publisher id with trailing blanks removed. """ return _pyiso9660.get_publisher_id(*args) def ifs_get_publisher_id(*args): """ Get the publisher ID. Return None if there is some problem in getting this. """ return _pyiso9660.ifs_get_publisher_id(*args) def get_pvd_type(*args): """ Get the publisher ID. Return None if there is some problem in getting this. """ return _pyiso9660.get_pvd_type(*args) def get_pvd_id(*args): """ Get the publisher ID. Return None if there is some problem in getting this. """ return _pyiso9660.get_pvd_id(*args) def get_pvd_space_size(*args): """ Get the publisher ID. Return None if there is some problem in getting this. """ return _pyiso9660.get_pvd_space_size(*args) def get_pvd_block_size(*args): """ Get the publisher ID. Return None if there is some problem in getting this. """ return _pyiso9660.get_pvd_block_size(*args) def get_pvd_version(*args): """ Return the primary volume id version number (of pvd). If there is an error 0 is returned. """ return _pyiso9660.get_pvd_version(*args) def get_system_id(*args): """ Return a string containing the PVD's system id with trailing blanks removed. """ return _pyiso9660.get_system_id(*args) def ifs_get_system_id(*args): """ Get the system ID. None is returned if there is some problem in getting this. """ return _pyiso9660.ifs_get_system_id(*args) def get_root_lsn(*args): """ Return the LSN of the root directory for pvd. If there is an error INVALID_LSN is returned. """ return _pyiso9660.get_root_lsn(*args) def get_volume_id(*args): """Return the PVD's volume ID.""" return _pyiso9660.get_volume_id(*args) def ifs_get_volume_id(*args): """ Get the system ID. None is returned if there is some problem in getting this. """ return _pyiso9660.ifs_get_volume_id(*args) def get_volumeset_id(*args): """ Return the PVD's volumeset ID. None is returned if there is some problem in getting this. """ return _pyiso9660.get_volumeset_id(*args) def ifs_get_volumeset_id(*args): """ Get the volumeset ID. None is returned if there is some problem in getting this. """ return _pyiso9660.ifs_get_volumeset_id(*args) def pathtable_init(*args): """Zero's out pathable. Do this first.""" return _pyiso9660.pathtable_init(*args) def pathtable_get_size(*args): """Zero's out pathable. Do this first.""" return _pyiso9660.pathtable_get_size(*args) def pathtable_l_add_entry(*args): """Zero's out pathable. Do this first.""" return _pyiso9660.pathtable_l_add_entry(*args) def pathtable_m_add_entry(*args): """Zero's out pathable. Do this first.""" return _pyiso9660.pathtable_m_add_entry(*args) def set_evd(*args): """Zero's out pathable. Do this first.""" return _pyiso9660.set_evd(*args) def is_xa(*args): """Return true if ISO 9660 image has extended attrributes (XA).""" return _pyiso9660.is_xa(*args)