| java.lang.Object org.w3c.tools.resources.upgrade.Upgrader
Upgrader | public class Upgrader (Code) | | version: $Revision: 1.6 $ author: Benoît Mahé (bmahe@w3.org) |
debug | final public static boolean debug(Code) | | |
Upgrader | public Upgrader(String server, File config, File props, Serializer serializer)(Code) | | Constructor
Parameters: server - the server name Parameters: config - the server config directory Parameters: props - the server properties file Parameters: serializer - the XML Serializer |
backupStores | protected void backupStores(File storedir, FilenameFilter filter) throws IOException(Code) | | backup the stores under the given store directory.
Parameters: storedir - the store directory Parameters: filter - the filter to use to list the stores |
cleanStores | protected void cleanStores(File storedir, FilenameFilter filter) throws IOException(Code) | | clean the stores under the given store directory.
Parameters: storedir - the store directory Parameters: filter - the filter to use to list the stores |
createSubDirs | protected boolean createSubDirs(File storedir)(Code) | | Create the subdirectories under /stores.
|
getNewStore | protected File getNewStore(File storedir, File oldstore)(Code) | | Get the new store location.
Parameters: oldstore - the Old store. a File instance |
lookupAttribute | public static int lookupAttribute(String name, org.w3c.tools.resources.Attribute attributes)(Code) | | Get the index of the given attribute in the given attribute array
name, the attribute name. attributes, the atribute array. an int |
updateProperties | protected void updateProperties(int version)(Code) | | Update the properties to add the serializer class in it.
|
upgrade | public void upgrade(int version) throws IOException, UpgradeException(Code) | | The big stuff, upgrade the configuration in XML
- Upgrade the resource stores
- Upgrade the indexers (if any)
- Upgrade the realms (if any)
- Upgrade the properties files
exception: IOException - if an IO error occurs |
upgradeDB | protected void upgradeDB(File storedir, FilenameFilter filter)(Code) | | Upgrade the stores (.db) under the given store directory.
Parameters: storedir - the store directory Parameters: filter - the filter to use to list the stores |
upgradeStores | protected void upgradeStores(File storedir, FilenameFilter filter) throws UpgradeException(Code) | | Upgrade the stores (st-xxx) under the given store directory.
Parameters: storedir - the store directory Parameters: filter - the filter to use to list the stores |
usage | public static void usage()(Code) | | |
|
|