Logo Search packages:      
Sourcecode: gallery-uploader version File versions  Download package

def guplib::gallery::Gallery::__init__ (   self,
  url,
  user,
  password 
)

Class initiator.

url      - Gallery installation URL
user     - login user
password - user passowrd

Definition at line 164 of file gallery.py.

00164                                            :
        '''Class initiator.

        url      - Gallery installation URL
        user     - login user
        password - user passowrd'''

        self.logged   = False
        self.cookie   = None
        self.url      = url + '/main.php'
        self.user     = user
        self.password = password
        self.last_authtoken = ''

        # maps return codes to the exceptions
        self._return_codes = {
                101: MajorVersionInvalidError,
                102: MinorVersionInvalidError,
                103: ProtocolFormatInvalidError,
                104: MissingProtocolVersionError,
                201: InvalidPasswordError,
                202: MissingLoginError,
                301: InvalidCommandError,
                401: NoPermissionError,
                402: NoFilenameError,
                403: PhotoUploadError,
                404: NoWritePermissionError,
                405: NoViewPermissionError,
                501: NoAlbumPermissionError,
                502: AlbumCreateError,
                503: MoveAlbumError,
                504: ImageRotateError
                }

    def request(self, command, version, arguments, file_info = None):


Generated by  Doxygen 1.6.0   Back to index