Dali Provisional API
Release 3.2

org.eclipse.jpt.jpa.core
Interface JpaStructureNode

All Superinterfaces:
IAdaptable, JpaContextModel, JpaModel, JptResourceTypeReference, Model
All Known Subinterfaces:
ClassRef, EclipseLinkEntityMappings, EclipseLinkOrmPersistentType, EntityMappings, JarFileRef, JavaPersistentAttribute, JavaPersistentType, JavaSpecifiedPersistentAttribute, MappingFile.Root, MappingFileRef, OrmPersistentAttribute, OrmPersistentType, OrmSpecifiedPersistentAttribute, Persistence, Persistence2_0, PersistenceUnit, PersistenceUnit2_0, PersistentAttribute, PersistentAttribute2_0, PersistentType, PersistentType2_0, SpecifiedPersistentAttribute, SpecifiedPersistentAttribute2_0, XmlFile.Root
All Known Implementing Classes:
org.eclipse.jpt.jpa.core.internal.context.persistence.AbstractPersistenceUnit, EclipseLinkPersistenceUnit

public interface JpaStructureNode
extends JpaContextModel

Interface implemented by any object to appear in the JPA Structure view and JPA Details view. This interface is also used by the JPA Selection Managers.

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.0

Nested Class Summary
static class JpaStructureNode.ContextType
          Type used to identify a JPA structure node's type with respect to the structure node's context (i.e. its type in the scope of the JPA platform that created the structure node and the structure node's resource).
 
Nested classes/interfaces inherited from interface org.eclipse.jpt.jpa.core.JpaModel
JpaModel.JpaVersionIsCompatibleWith
 
Nested classes/interfaces inherited from interface org.eclipse.jpt.common.core.JptResourceTypeReference
JptResourceTypeReference.ResourceTypeIsKindOf, JptResourceTypeReference.ResourceTypeTransformer
 
Field Summary
static String STRUCTURE_CHILDREN_COLLECTION
          String constant associated with changes to the structure node's children.
 
Fields inherited from interface org.eclipse.jpt.common.core.JptResourceTypeReference
TRANSFORMER
 
Method Summary
 void addRootStructureNodesTo(JpaFile jpaFile, Collection<JpaStructureNode> rootStructureNodes)
          Add the to the specified collection the specified JPA file's root structure nodes (i.e. the nodes that will be the root elements in the JPA Structure view when the JPA file is displayed by the active editor).
 boolean containsOffset(int textOffset)
          Return whether the structure node's full text representation contains the specified text offset.
 JpaStructureNode.ContextType getContextType()
          Return the structure node's context type.
 TextRange getFullTextRange()
          Return the text range for the structure node's full text representation.
 TextRange getSelectionTextRange()
          Return the text range to be used to select text in the editor corresponding to the structure node.
 Iterable<? extends JpaStructureNode> getStructureChildren()
          Return the node's children, as to be displayed in the JPA Structure view.
 int getStructureChildrenSize()
          Return the number of the node's children.
 JpaStructureNode getStructureNode(int textOffset)
          Return the structure node at the specified offset in the structure node's corresponding text file.
 Class<? extends JpaStructureNode> getStructureType()
          Return the structure node's type.
 
Methods inherited from interface org.eclipse.jpt.jpa.core.context.JpaContextModel
getCompletionProposals, getContextDefaultDbCatalog, getContextDefaultDbSchema, getContextDefaultDbSchemaContainer, getMappingFileRoot, getParent, getPersistenceUnit, getValidationTextRange, synchronizeWithResourceModel, update, validate
 
Methods inherited from interface org.eclipse.jpt.jpa.core.JpaModel
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
 

Field Detail

STRUCTURE_CHILDREN_COLLECTION

static final String STRUCTURE_CHILDREN_COLLECTION
String constant associated with changes to the structure node's children.

See Also:
Constant Field Values
Method Detail

getFullTextRange

TextRange getFullTextRange()
Return the text range for the structure node's full text representation.

See Also:
getSelectionTextRange()

containsOffset

boolean containsOffset(int textOffset)
Return whether the structure node's full text representation contains the specified text offset.

See Also:
getFullTextRange()

getStructureNode

JpaStructureNode getStructureNode(int textOffset)
Return the structure node at the specified offset in the structure node's corresponding text file.


getSelectionTextRange

TextRange getSelectionTextRange()
Return the text range to be used to select text in the editor corresponding to the structure node.

See Also:
getFullTextRange()

getContextType

JpaStructureNode.ContextType getContextType()
Return the structure node's context type. Type used to identify a JPA structure node's type with respect to the structure node's context (i.e. its type in the scope of the JPA platform that created the structure node and the structure node's resource).

See Also:
JpaModel.getJpaPlatform(), JptResourceTypeReference.getResourceType(), getStructureType()

getStructureType

Class<? extends JpaStructureNode> getStructureType()
Return the structure node's type. This is used to find the appropriate UI provider for building the structure node's JPA Details page.


addRootStructureNodesTo

void addRootStructureNodesTo(JpaFile jpaFile,
                             Collection<JpaStructureNode> rootStructureNodes)
Add the to the specified collection the specified JPA file's root structure nodes (i.e. the nodes that will be the root elements in the JPA Structure view when the JPA file is displayed by the active editor).

See Also:
JpaFile.getRootStructureNodes()

getStructureChildren

Iterable<? extends JpaStructureNode> getStructureChildren()
Return the node's children, as to be displayed in the JPA Structure view.


getStructureChildrenSize

int getStructureChildrenSize()
Return the number of the node's children.

See Also:
getStructureChildren()

Dali Provisional API
Release 3.2

Copyright (c) 2012 Oracle. All rights reserved.