public class XBMCWebUpdater extends XMLParser implements IXBMCUpdater
DTD_WEB_LOCATION, SCHEMA_WEB_LOCATION
Constructor and Description |
---|
XBMCWebUpdater(ConfigReader config)
The constructor
|
Modifier and Type | Method and Description |
---|---|
protected java.io.File |
downloadLatestAddonXML() |
int |
installAddons(IConsole console,
java.util.Set<java.lang.String> addonIds)
Used to install a list of addons
|
java.util.Set<AddonDetails> |
listAddons(IConsole console)
Used to get a list of installed and uninstalled addons
|
void |
setAddonManager(XBMCAddonManager mgr)
Register the XBMC manager with the updater
|
int |
uninstallAddons(IConsole console,
java.util.Set<java.lang.String> addonIds)
Used to uninstall a list of addons and any that depend on these addons
|
int |
update(IConsole console)
Update all addons to the latest version
|
int |
update(IConsole console,
java.util.Set<java.lang.String> pluginList)
Update a list of addons to the latest version and the addons they depend on
|
protected int |
updatePlugins(IConsole console,
java.io.File newAddon,
java.util.Set<java.lang.String> plugins) |
createDocBuilder, createFactory, deleteNode, domToStr, domToStrNoXMLProlog, encodeAttributeValue, firstChild, fixXMl, getAttribute, getElement, getFirstChildElement, getFloatFromXML, getIntegerFromXML, getLastChildElement, getLongFromXML, getSchema, getStringFromXML, getStringFromXMLOrNull, getURLFromXML, getURLFromXMLOrNull, hasNode, parse, parse, parse, quoteXPathQuery, selectChildNodes, selectNodeList, selectSingleNode, strToDom, strToDom, strToDom, writeXML
public XBMCWebUpdater(ConfigReader config) throws XBMCException
config
- The Media directory configurationXBMCException
- Thrown if their is a problem reading from the configurationpublic void setAddonManager(XBMCAddonManager mgr)
setAddonManager
in interface IXBMCUpdater
mgr
- the XBMC managerpublic java.util.Set<AddonDetails> listAddons(IConsole console) throws XBMCUpdaterException
listAddons
in interface IXBMCUpdater
console
- The console used to send messages toXBMCUpdaterException
- thrown if their are any problemspublic int installAddons(IConsole console, java.util.Set<java.lang.String> addonIds) throws XBMCException
installAddons
in interface IXBMCUpdater
console
- The console used to send messages toaddonIds
- a list of addon ID's to installXBMCException
- Thrown if their are any problemspublic int uninstallAddons(IConsole console, java.util.Set<java.lang.String> addonIds) throws XBMCUpdaterException
uninstallAddons
in interface IXBMCUpdater
console
- The console used to send messages toaddonIds
- a list of addon ID's to uninstallXBMCUpdaterException
- Thrown if their are any problemspublic int update(IConsole console, java.util.Set<java.lang.String> pluginList) throws XBMCException
update
in interface IXBMCUpdater
console
- The console used to send messages topluginList
- The list of addons to updateXBMCUpdaterException
- thrown if their are any problems with the updaterXBMCException
- Thrown if their are any other problemspublic int update(IConsole console) throws XBMCException
update
in interface IXBMCUpdater
console
- The console used to send messages toXBMCUpdaterException
- thrown if their are any problems with the updaterXBMCException
- Thrown if their are any other problemsprotected int updatePlugins(IConsole console, java.io.File newAddon, java.util.Set<java.lang.String> plugins) throws XMLParserException, java.io.IOException, XBMCUpdaterException, XBMCException
XMLParserException
java.io.IOException
XBMCUpdaterException
XBMCException
protected java.io.File downloadLatestAddonXML() throws java.io.IOException, XBMCUpdaterException
java.io.IOException
XBMCUpdaterException