Dali Provisional API
Release 3.2

org.eclipse.jpt.jpa.core
Interface JpaPlatform

All Superinterfaces:
IAdaptable

public interface JpaPlatform
extends IAdaptable

This interface is to be implemented by a JPA vendor to provide extensions to the core JPA model. The core JPA model will provide functionality for JPA spec annotations in Java, persistence.xml and mapping (orm.xml) files. The org.eclipse.jpt.jpa.core.generic extension supplies resource models for those file types. As another vendor option you will have to supply those resource models as well or different ones as necessary. In the extension point you actually provide a JpaPlatformFactory that will build the JPA platform.

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.

See the org.eclipse.jpt.jpa.core.jpaPlatforms extension point.

Since:
2.0
See Also:
JpaPlatformFactory, JpaPlatformProvider

Nested Class Summary
static interface JpaPlatform.Config
          Metadata that describes a JPA platform as defined in an extension to the org.eclipse.jpt.jpa.core.jpaPlatforms extension point.
static interface JpaPlatform.GroupConfig
          Metadata that describes a JPA platform group as defined in an extension to the org.eclipse.jpt.jpa.core.jpaPlatforms extension point.
static interface JpaPlatform.Version
           
 
Method Summary
 JpaFile buildJpaFile(JpaProject jpaProject, IFile file)
          Return a JPA file corresponding to the specified Eclipse file.
 AnnotationEditFormatter getAnnotationEditFormatter()
          Return a formatter that can clean up the Java annotations added to source code.
 AnnotationProvider getAnnotationProvider()
          Return an annotation provider responsible for determining what Java annotations are supported and constructing the corresponding Java resource model objects.
 JpaPlatform.Config getConfig()
          Return the JPA platform's config (i.e. the config defined by the JPA platform's plug-in extension).
 ConnectionProfileFactory getConnectionProfileFactory()
          Return a connection factory that can be used to query the database about its metadata etc.
 IContentType getContentType(IFile file)
          Return the specified file's content type, as defined by various extensions.
 Iterable<DefaultJavaAttributeMappingDefinition> getDefaultJavaAttributeMappingDefinitions()
          Return the Java attribute mapping definitions that will be used to build default Java attribute mappings.
 JpaEntityGeneratorDatabaseAnnotationNameBuilder getEntityGeneratorDatabaseAnnotationNameBuilder()
          Return an entity generator database annotation name builder, which is used by Entity Generation to determine whether and how the entity generator prints the names of various database objects.
 String getId()
          Return the JPA platform's ID.
 Iterable<JavaManagedTypeDefinition> getJavaManagedTypeDefinitions()
          Return the Java managed type definitions that will be used to build Java managed types and their corresponding annotations.
 Iterable<JavaTypeMappingDefinition> getJavaTypeMappingDefinitions()
          Return the Java type mapping definitions that will be used to build Java type mappings and their corresponding annotations.
 JpaFactory getJpaFactory()
          Return the factory responsible for constructing various JPA model objects: core (e.g.
 JpaPlatformVariation getJpaVariation()
          Return a JPA platform variation that is used to determine differences among JPA platforms and/or JPA specification versions.
 JpaPlatform.Version getJpaVersion()
          Return the JPA platform's version.
 JPQLGrammar getJpqlGrammar()
          Return the JPQL grammar that will be used to parse JPQL queries.
 JptResourceType getMostRecentSupportedResourceType(IContentType contentType)
          Return the most recent supported resource type for the specified content type.
 JpaResourceDefinition getResourceDefinition(JptResourceType resourceType)
          Return the JPA platform's resource definition for the specified resource type.
 Iterable<JavaAttributeMappingDefinition> getSpecifiedJavaAttributeMappingDefinitions()
          Return the Java attribute mapping definitions that will be used to build Java attribute mappings and their corresponding annotations.
 boolean supportsResourceType(JptResourceType resourceType)
          Return whether the JPA platform supports the specified resource type.
 
Methods inherited from interface org.eclipse.core.runtime.IAdaptable
getAdapter
 

Method Detail

getId

String getId()
Return the JPA platform's ID.


getConfig

JpaPlatform.Config getConfig()
Return the JPA platform's config (i.e. the config defined by the JPA platform's plug-in extension).


getJpaVersion

JpaPlatform.Version getJpaVersion()
Return the JPA platform's version.


getJpaFactory

JpaFactory getJpaFactory()
Return the factory responsible for constructing various JPA model objects:


buildJpaFile

JpaFile buildJpaFile(JpaProject jpaProject,
                     IFile file)
Return a JPA file corresponding to the specified Eclipse file. Return null if the file's content is unsupported.


getContentType

IContentType getContentType(IFile file)
Return the specified file's content type, as defined by various extensions.


getJavaManagedTypeDefinitions

Iterable<JavaManagedTypeDefinition> getJavaManagedTypeDefinitions()
Return the Java managed type definitions that will be used to build Java managed types and their corresponding annotations.


getAnnotationProvider

AnnotationProvider getAnnotationProvider()
Return an annotation provider responsible for determining what Java annotations are supported and constructing the corresponding Java resource model objects.


getAnnotationEditFormatter

AnnotationEditFormatter getAnnotationEditFormatter()
Return a formatter that can clean up the Java annotations added to source code.


getJavaTypeMappingDefinitions

Iterable<JavaTypeMappingDefinition> getJavaTypeMappingDefinitions()
Return the Java type mapping definitions that will be used to build Java type mappings and their corresponding annotations.


getSpecifiedJavaAttributeMappingDefinitions

Iterable<JavaAttributeMappingDefinition> getSpecifiedJavaAttributeMappingDefinitions()
Return the Java attribute mapping definitions that will be used to build Java attribute mappings and their corresponding annotations.


getDefaultJavaAttributeMappingDefinitions

Iterable<DefaultJavaAttributeMappingDefinition> getDefaultJavaAttributeMappingDefinitions()
Return the Java attribute mapping definitions that will be used to build default Java attribute mappings.


supportsResourceType

boolean supportsResourceType(JptResourceType resourceType)
Return whether the JPA platform supports the specified resource type. This method is consistent with getResourceDefinition(JptResourceType).


getResourceDefinition

JpaResourceDefinition getResourceDefinition(JptResourceType resourceType)
Return the JPA platform's resource definition for the specified resource type. The returned definition describes the JPA platform's corresponding context model. Throw an IllegalArgumentException if the resource type is not supported by the JPA platform. This method is consistent with supportsResourceType(JptResourceType).


getMostRecentSupportedResourceType

JptResourceType getMostRecentSupportedResourceType(IContentType contentType)
Return the most recent supported resource type for the specified content type. Throw an IllegalArgumentException if the content type is not supported by the JPA platform.


getConnectionProfileFactory

ConnectionProfileFactory getConnectionProfileFactory()
Return a connection factory that can be used to query the database about its metadata etc.


getEntityGeneratorDatabaseAnnotationNameBuilder

JpaEntityGeneratorDatabaseAnnotationNameBuilder getEntityGeneratorDatabaseAnnotationNameBuilder()
Return an entity generator database annotation name builder, which is used by Entity Generation to determine whether and how the entity generator prints the names of various database objects.


getJpaVariation

JpaPlatformVariation getJpaVariation()
Return a JPA platform variation that is used to determine differences among JPA platforms and/or JPA specification versions.


getJpqlGrammar

JPQLGrammar getJpqlGrammar()
Return the JPQL grammar that will be used to parse JPQL queries.

Since:
3.2

Dali Provisional API
Release 3.2

Copyright (c) 2012 Oracle. All rights reserved.