org.openstreetmap.osmosis.core.util
Class PropertiesPersister

java.lang.Object
  extended by org.openstreetmap.osmosis.core.util.PropertiesPersister

public class PropertiesPersister
extends java.lang.Object

Allows Properties objects to be loaded and stored to file.


Constructor Summary
PropertiesPersister(java.io.File propertiesFile)
          Creates a new instance.
 
Method Summary
 boolean exists()
          Checks if the properties file exists.
 java.util.Properties load()
          Loads the properties from the file.
 void store(java.util.Properties properties)
          Stores the properties to the file overwriting any existing file contents.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PropertiesPersister

public PropertiesPersister(java.io.File propertiesFile)
Creates a new instance.

Parameters:
propertiesFile - The location of the file containing the persisted data.
Method Detail

load

public java.util.Properties load()
Loads the properties from the file.

Returns:
The properties.

store

public void store(java.util.Properties properties)
Stores the properties to the file overwriting any existing file contents.

Parameters:
properties - The properties.

exists

public boolean exists()
Checks if the properties file exists.

Returns:
True if a file exists, false otherwise.