org.eclipse.jpt.core.context.persistence
Interface PersistenceXml

All Superinterfaces:
org.eclipse.core.runtime.IAdaptable, JpaContextNode, JpaNode, JpaStructureNode, Model, PersistenceJpaContextNode

public interface PersistenceXml
extends PersistenceJpaContextNode, JpaStructureNode

Provisional API: This interface is part of an interim API that is still under development and expected to change significantly before reaching stability. It is available at this early stage to solicit feedback from pioneering adopters on the understanding that any code that uses this API will almost certainly be broken (repeatedly) as the API evolves.


Field Summary
static java.lang.String PERSISTENCE_PROPERTY
          String constant associated with changes to the persistence property
 
Method Summary
 Persistence addPersistence()
          Add a persistence node to the persistence.xml file and return the object representing it.
 Persistence getPersistence()
          Return the content represented by the root of the persistence.xml file.
 void removePersistence()
          Remove the persistence node from the persistence.xml file.
 void update(PersistenceResource persistenceResource)
           
 
Methods inherited from interface org.eclipse.jpt.core.context.persistence.PersistenceJpaContextNode
addToMessages, getValidationTextRange
 
Methods inherited from interface org.eclipse.jpt.core.context.JpaContextNode
getEntityMappings, getOrmPersistentType, getPersistenceUnit
 
Methods inherited from interface org.eclipse.jpt.core.JpaNode
getJpaProject, getParent, getResource
 
Methods inherited from interface org.eclipse.jpt.utility.model.Model
addCollectionChangeListener, addCollectionChangeListener, addListChangeListener, addListChangeListener, addPropertyChangeListener, addPropertyChangeListener, addStateChangeListener, addTreeChangeListener, addTreeChangeListener, removeCollectionChangeListener, removeCollectionChangeListener, removeListChangeListener, removeListChangeListener, removePropertyChangeListener, removePropertyChangeListener, removeStateChangeListener, removeTreeChangeListener, removeTreeChangeListener
 
Methods inherited from interface org.eclipse.core.runtime.IAdaptable
getAdapter
 
Methods inherited from interface org.eclipse.jpt.core.JpaStructureNode
dispose, getId, getSelectionTextRange, getStructureNode
 

Field Detail

PERSISTENCE_PROPERTY

static final java.lang.String PERSISTENCE_PROPERTY
String constant associated with changes to the persistence property

See Also:
Constant Field Values
Method Detail

getPersistence

Persistence getPersistence()
Return the content represented by the root of the persistence.xml file. This may be null.


addPersistence

Persistence addPersistence()
Add a persistence node to the persistence.xml file and return the object representing it. Throws IllegalStateException if a persistence node already exists.


removePersistence

void removePersistence()
Remove the persistence node from the persistence.xml file. Throws IllegalStateException if a persistence node does not exist.


update

void update(PersistenceResource persistenceResource)