Package moul :: Package file :: Module kiimage :: Class KIImageFixer
[hide private]
[frames] | no frames]

Class KIImageFixer



object --+
         |
        KIImageFixer

Create fixed images in a new directory

Instance Methods [hide private]
  __init__(self, srcdir, destdir)
x.__init__(...) initializes x; see x.__class__.__doc__ for signature
  findFiles(self)
Find files
  checkAndCopyFile(self, kiname, fixedname)
Check and copy file
  __len__(self)
len() support - returns number of images to check
  __iter__(self)
Iterate over the files to check

Inherited from object: __delattr__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __str__


Static Methods [hide private]
  mkFixedName(path, name, dest)
Make new new based on the name of the KI image

Class Variables [hide private]
  _pat = ('*.jpg',)

Properties [hide private]

Inherited from object: __class__


Method Details [hide private]

__init__(self, srcdir, destdir)
(Constructor)

 
x.__init__(...) initializes x; see x.__class__.__doc__ for signature
Overrides: object.__init__
(inherited documentation)

mkFixedName(path, name, dest)
Static Method

 
Make new new based on the name of the KI image
Parameters:
  • path (str) - directory where the file lives
  • name (str) - name of the image w/o path
Returns:
KIimage_moddate_number.ext
Decorators:

findFiles(self)

 
Find files

checkAndCopyFile(self, kiname, fixedname)

 

Check and copy file

If the file is a KI image than copy the file to the new location

__len__(self)
(Length operator)

 
len() support - returns number of images to check

__iter__(self)

 

Iterate over the files to check

Calls checkAndCopyFiles() for each element. This method is used to update a progress bar in the UI.

Class Variable Details [hide private]

_pat

None
Value:
('*.jpg',)