def __init__( self , name, type ): #self.itemId = itemId # Id of the server item self.name = name # Name of the item self.type = type # XBMC Type of the item #self.typeInstallPath = installPath # Install Path for this type of item self.typeInstallPath = Item.get_install_path( type ) # Install Path for this type of item #self.filesize = filesize # Size of the file to download self.configManager = CONF.configCtrl() if not self.configManager.is_conf_valid: raise self.CACHEDIR = self.configManager.CACHEDIR self.fileMgr = fileMgr() # NOTE: need to be set in a subclass before calling isAlreadyInstalled or deleteInstalledItem self.scraperName = None self.scraperFileList = None # List of teh file for a scraper (xml, image ...) #self.installNameList = None self.installName = None # Name of the addon used by XBMC: i.e script dir name, plugin dir name, skin dir name, scraper xml file name self.destinationPath = None # self.status = "INIT" # Status of install :[ INIT | OK | ERROR | DOWNLOADED | EXTRACTED | ALREADYINSTALLED | ALREADYINUSE | CANCELED | INSTALL_DONE ]