Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.flexdock.perspective.persist
Class FilePersistenceHandler

    java.lang.Object
      org.flexdock.perspective.persist.FilePersistenceHandler

All Implemented Interfaces:
  PersistenceHandler

    public class FilePersistenceHandler

extends Object
implements PersistenceHandler

Created on 2005-06-03

Version:
  $Id: FilePersistenceHandler.java,v 1.9 2006-12-20 20:55:22 kschaefe Exp $
Author:
  Mateusz Szczap

Field Summary
`static File` | `DEFAULT_PERSPECTIVE_DIR`
`protected File` | `defaultPerspectiveFile`
`protected Persister` | `m_persister`

Constructor Summary
`FilePersistenceHandler(File file)`
`FilePersistenceHandler(File defaultFile, Persister persister)`
`FilePersistenceHandler(String absolutePath)`
`FilePersistenceHandler(String absolutePath, Persister persister)`

Method Summary
`static FilePersistenceHandler` | `createDefault(String fileName)`
`Persister` | `createDefaultPersister()`
`File` | `getPerspectiveFile(String persistenceKey)`
`PerspectiveModel` | `load(String persistenceKey)`
`void` | `setDefaultPerspectiveFile(File file)`
`void` | `setDefaultPerspectiveFile(String absolutePath)`
`boolean` | `store(String persistenceKey, PerspectiveModel perspectiveModel)`
`protected void` | `validatePerspectiveFile(File file)`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### DEFAULT_PERSPECTIVE_DIR

    public static final File DEFAULT_PERSPECTIVE_DIR

### defaultPerspectiveFile

    protected File defaultPerspectiveFile

### m_persister

    protected Persister m_persister

Constructor Detail

### FilePersistenceHandler

    public FilePersistenceHandler(String absolutePath)

### FilePersistenceHandler

    public FilePersistenceHandler(File file)

### FilePersistenceHandler

    public FilePersistenceHandler(String absolutePath,
                                  Persister persister)

### FilePersistenceHandler

    public FilePersistenceHandler(File defaultFile,
                                  Persister persister)

Method Detail

### createDefault

    public static FilePersistenceHandler createDefault(String fileName)

### store

    public boolean store(String persistenceKey,
                         PerspectiveModel perspectiveModel)
                  throws IOException,
                         PersistenceException

  Specified by:
    `store` in interface `PersistenceHandler`
  Throws:
    `IOException`
    `PersistenceException`

### load

    public PerspectiveModel load(String persistenceKey)
                          throws IOException,
                                 PersistenceException

  Specified by:
    `load` in interface `PersistenceHandler`
  Throws:
    `IOException`
    `PersistenceException`

### validatePerspectiveFile

    protected void validatePerspectiveFile(File file)
                                    throws IOException

  Throws:
    `IOException`

### getPerspectiveFile

    public File getPerspectiveFile(String persistenceKey)

### setDefaultPerspectiveFile

    public void setDefaultPerspectiveFile(File file)

### setDefaultPerspectiveFile

    public void setDefaultPerspectiveFile(String absolutePath)

### createDefaultPersister

    public Persister createDefaultPersister()

  Specified by:
    `createDefaultPersister` in interface `PersistenceHandler`

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD