Dali Provisional API
Release 3.2

org.eclipse.jpt.jpa.core.context
Interface MappingFile

All Superinterfaces:
DeleteTypeRefactoringParticipant, IAdaptable, JpaContextNode, JpaNode, JptResourceTypeReference, ManagedTypeContainer, Model, PersistentTypeContainer, TypeRefactoringParticipant
All Known Subinterfaces:
OrmXml

public interface MappingFile
extends JpaContextNode, PersistentTypeContainer, DeleteTypeRefactoringParticipant, TypeRefactoringParticipant

JPA mapping file (typically orm.xml).

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.

Since:
2.1

Nested Class Summary
static interface MappingFile.Root
          Common interface for the root of a mapping file.
 
Nested classes/interfaces inherited from interface org.eclipse.jpt.common.core.JptResourceTypeReference
JptResourceTypeReference.ResourceTypeTransformer
 
Nested classes/interfaces inherited from interface org.eclipse.jpt.jpa.core.context.persistence.PersistentTypeContainer
PersistentTypeContainer.PersistentTypesTransformer
 
Nested classes/interfaces inherited from interface org.eclipse.jpt.jpa.core.context.DeleteTypeRefactoringParticipant
DeleteTypeRefactoringParticipant.DeleteTypeEditsTransformer
 
Nested classes/interfaces inherited from interface org.eclipse.jpt.jpa.core.context.TypeRefactoringParticipant
TypeRefactoringParticipant.MoveTypeEditsTransformer, TypeRefactoringParticipant.RenamePackageEditsTransformer, TypeRefactoringParticipant.RenameTypeEditsTransformer
 
Field Summary
static String ROOT_PROPERTY
          String constant associated with changes to the root property.
 
Fields inherited from interface org.eclipse.jpt.common.core.JptResourceTypeReference
RESOURCE_TYPE_TRANSFORMER
 
Fields inherited from interface org.eclipse.jpt.jpa.core.context.persistence.PersistentTypeContainer
TRANSFORMER
 
Method Summary
 void dispose()
          Dispose the structure node and its children.
 void gatherRootStructureNodes(JpaFile jpaFile, Collection<JpaStructureNode> rootStructureNodes)
          Add the appropriate root structure nodes to the collection that correspond to the given JPA file.
 MappingFileDefinition getDefinition()
          Return the mapping file's definition.
 Iterable<Generator> getMappingFileGenerators()
          Return the generators defined directly in the mapping file (as opposed to including the generators defined in Java types referenced by the mapping file).
 Iterable<Query> getMappingFileQueries()
          Return the queries defined directly in the mapping file (as opposed to including the queries defined in Java types referenced by the mapping file).
 MappingFileRef getParent()
          Return the JPA node's parent.
 Object getResourceMappingFile()
          Return the corresponding resource mapping file.
 MappingFile.Root getRoot()
          Return the mapping file's root.
 boolean isIn(IFolder folder)
          Return whether the mapping file exists in the specified folder.
 
Methods inherited from interface org.eclipse.jpt.jpa.core.context.JpaContextNode
getCompletionProposals, getContextDefaultDbCatalog, getContextDefaultDbSchema, getContextDefaultDbSchemaContainer, getMappingFileRoot, getPersistenceUnit, getValidationTextRange, synchronizeWithResourceModel, update, validate
 
Methods inherited from interface org.eclipse.jpt.jpa.core.JpaNode
getJpaPlatform, getJpaProject, getJpaProjectManager, getResource, stateChanged
 
Methods inherited from interface org.eclipse.jpt.common.utility.model.Model
addChangeListener, addCollectionChangeListener, addListChangeListener, addPropertyChangeListener, addStateChangeListener, removeChangeListener, removeCollectionChangeListener, removeListChangeListener, removePropertyChangeListener, removeStateChangeListener
 
Methods inherited from interface org.eclipse.core.runtime.IAdaptable
getAdapter
 
Methods inherited from interface org.eclipse.jpt.common.core.JptResourceTypeReference
getResourceType
 
Methods inherited from interface org.eclipse.jpt.jpa.core.context.persistence.PersistentTypeContainer
getPersistentType, getPersistentTypes
 
Methods inherited from interface org.eclipse.jpt.jpa.core.context.persistence.ManagedTypeContainer
getManagedType, getManagedTypes
 
Methods inherited from interface org.eclipse.jpt.jpa.core.context.DeleteTypeRefactoringParticipant
createDeleteTypeEdits
 
Methods inherited from interface org.eclipse.jpt.jpa.core.context.TypeRefactoringParticipant
createMoveTypeEdits, createRenamePackageEdits, createRenameTypeEdits
 

Field Detail

ROOT_PROPERTY

static final String ROOT_PROPERTY
String constant associated with changes to the root property.

See Also:
Constant Field Values
Method Detail

getParent

MappingFileRef getParent()
Description copied from interface: JpaNode
Return the JPA node's parent. The JPA project will not have a parent.

Specified by:
getParent in interface JpaContextNode
Specified by:
getParent in interface JpaNode

getRoot

MappingFile.Root getRoot()
Return the mapping file's root. This can be null.


getDefinition

MappingFileDefinition getDefinition()
Return the mapping file's definition.


isIn

boolean isIn(IFolder folder)
Return whether the mapping file exists in the specified folder.


getResourceMappingFile

Object getResourceMappingFile()
Return the corresponding resource mapping file. The type of the returned resource mapping file is determined by the implementation and its clients.


gatherRootStructureNodes

void gatherRootStructureNodes(JpaFile jpaFile,
                              Collection<JpaStructureNode> rootStructureNodes)
Add the appropriate root structure nodes to the collection that correspond to the given JPA file.

See Also:
JpaFile.getRootStructureNodes()

dispose

void dispose()
Dispose the structure node and its children. Typically this would be used to update the structure node's JPA file's root structure nodes.


getMappingFileQueries

Iterable<Query> getMappingFileQueries()
Return the queries defined directly in the mapping file (as opposed to including the queries defined in Java types referenced by the mapping file).


getMappingFileGenerators

Iterable<Generator> getMappingFileGenerators()
Return the generators defined directly in the mapping file (as opposed to including the generators defined in Java types referenced by the mapping file).


Dali Provisional API
Release 3.2

Copyright (c) 2012 Oracle. All rights reserved.