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

## org.apache.cayenne.project
Class ApplicationProject

    java.lang.Object
      org.apache.cayenne.project.Project
          org.apache.cayenne.project.ApplicationProject

    public class ApplicationProject

extends Project

Represents Cayenne application project.

Author:
  Andrei Adamchik

Field Summary
`protected Configuration` | `configuration`

Fields inherited from class org.apache.cayenne.project.Project
`CURRENT_PROJECT_VERSION, files, modified, projectDir, upgradeMessages, upgradeStatus`

Constructor Summary
`ApplicationProject(java.io.File projectFile)` Constructor for ApplicationProject.
`ApplicationProject(java.io.File projectFile, Configuration configuration)`

Method Summary
`void` | `checkForUpgrades()` Determines whether the project needs to be upgraded.
`java.util.List` | `getChildren()` Returns a list of first-level children of the project.
`Configuration` | `getConfiguration()` Returns Cayenne configuration object associated with this project.
`ConfigStatus` | `getLoadStatus()`
`protected void` | `loadProject()`
`protected void` | `loadProject(java.io.File projectFile)` Deprecated. since 1.2
`protected void` | `postInitialize(java.io.File projectFile)` Initializes internal `Configuration` object and then calls super.
`ProjectFile` | `projectFileForObject(java.lang.Object obj)` Returns appropriate ProjectFile or null if object does not require a file of its own.
`protected boolean` | `requiresMapFile(java.lang.Object obj)`
`protected boolean` | `requiresNodeFile(java.lang.Object obj)`
`protected boolean` | `requiresProjectFile(java.lang.Object obj)`
`void` | `setConfiguration(ProjectConfiguration config)` Sets Cayenne configuration object associated with this project.
`void` | `upgrade()`

Methods inherited from class org.apache.cayenne.project.Project
`buildFileList, createProject, deleteFile, findFile, getMainFile, getProjectDirectory, getUpgradeMessages, getUpgradeStatus, getValidator, hasRenamedFiles, initialize, isLocationUndefined, isModified, isUpgradeNeeded, prepareSave, processDelete, processSave, resolveFile, resolveSymbolicName, save, setModified, setProjectDirectory, treeNodes`

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

Field Detail

### configuration

    protected Configuration configuration

Constructor Detail

### ApplicationProject

    public ApplicationProject(java.io.File projectFile)

  Constructor for ApplicationProject.

  Parameters:
    `projectFile` -

### ApplicationProject

    public ApplicationProject(java.io.File projectFile,
                              Configuration configuration)

Since:
  1.2

Method Detail

### upgrade

    public void upgrade()
                 throws ProjectException

  Specified by:
    `upgrade` in class `Project`
  Throws:
    `ProjectException`
  Since:
    1.1

### postInitialize

    protected void postInitialize(java.io.File projectFile)

  Initializes internal `Configuration` object and then calls super.

  Overrides:
    `postInitialize` in class `Project`

### loadProject

    protected void loadProject(java.io.File projectFile)
                        throws java.lang.Exception

  Deprecated. since 1.2

  Throws:
    `java.lang.Exception`
  Since:
    1.1

### loadProject

    protected void loadProject()

  Since:
    1.2

### getConfiguration

    public Configuration getConfiguration()

  Returns Cayenne configuration object associated with this project.

### setConfiguration

    public void setConfiguration(ProjectConfiguration config)

  Sets Cayenne configuration object associated with this project.

### checkForUpgrades

    public void checkForUpgrades()

  Description copied from class: `Project`
  Determines whether the project needs to be upgraded. Populates internal list of upgrade messages with discovered information.

  Specified by:
    `checkForUpgrades` in class `Project`

### getChildren

    public java.util.List getChildren()

  Description copied from class: `Project`
  Returns a list of first-level children of the project.

  Specified by:
    `getChildren` in class `Project`
  See Also:
    `Project.getChildren()`

### projectFileForObject

    public ProjectFile projectFileForObject(java.lang.Object obj)

  Returns appropriate ProjectFile or null if object does not require a file of its own. In case of ApplicationProject, the nodes that require separate filed are: the project itself, each DataMap, each driver DataNode.

  Specified by:
    `projectFileForObject` in class `Project`

### requiresProjectFile

    protected boolean requiresProjectFile(java.lang.Object obj)

### requiresMapFile

    protected boolean requiresMapFile(java.lang.Object obj)

### requiresNodeFile

    protected boolean requiresNodeFile(java.lang.Object obj)

### getLoadStatus

    public ConfigStatus getLoadStatus()

  Specified by:
    `getLoadStatus` in class `Project`
  Returns:
    An object describing failures in the loaded project.

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

Copyright © 2001-2006 Apache.org All Rights Reserved.