GigaSpaces XAP 9.7.2 API

org.openspaces.jpa
Class OpenSpacesPersistenceProvider

java.lang.Object
  extended by org.openspaces.jpa.OpenSpacesPersistenceProvider
All Implemented Interfaces:
javax.persistence.spi.PersistenceProvider

public class OpenSpacesPersistenceProvider
extends Object
implements javax.persistence.spi.PersistenceProvider

An OpenSpaces implementation for the PersistenceProvider interface. Provides an OpenJPA entity manager factory with an optional injected space instance.

Since:
8.0
Author:
idan

Constructor Summary
OpenSpacesPersistenceProvider()
           
 
Method Summary
 javax.persistence.EntityManagerFactory createContainerEntityManagerFactory(javax.persistence.spi.PersistenceUnitInfo pui, Map properties)
           
 javax.persistence.EntityManagerFactory createEntityManagerFactory(String persistenceUnitName, IJSpace space)
          Creates an EntityManagerFactory instance and injects the provided space instance to it.
 javax.persistence.EntityManagerFactory createEntityManagerFactory(String persistenceUnitName, IJSpace space, Map properties)
          Creates an EntityManagerFactory instance and injects the provided space instance to it.
 javax.persistence.EntityManagerFactory createEntityManagerFactory(String persistenceUnitName, Map properties)
           
 javax.persistence.spi.ProviderUtil getProviderUtil()
           
 void setSpace(IJSpace space)
          Sets the space instance which will be injected to the EntityManagerFactory instance.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

OpenSpacesPersistenceProvider

public OpenSpacesPersistenceProvider()
Method Detail

createEntityManagerFactory

public javax.persistence.EntityManagerFactory createEntityManagerFactory(String persistenceUnitName,
                                                                         IJSpace space,
                                                                         Map properties)
Creates an EntityManagerFactory instance and injects the provided space instance to it.

Parameters:
persistenceUnitName - The persistence unit name.
space - The space instance to inject.
properties - Properties map.
Returns:
EntityManagerFactory instance.

createEntityManagerFactory

public javax.persistence.EntityManagerFactory createEntityManagerFactory(String persistenceUnitName,
                                                                         IJSpace space)
Creates an EntityManagerFactory instance and injects the provided space instance to it.

Parameters:
persistenceUnitName - The persistence unit name.
space - The space instance to inject.
Returns:
EntityManagerFactory instance.

createEntityManagerFactory

public javax.persistence.EntityManagerFactory createEntityManagerFactory(String persistenceUnitName,
                                                                         Map properties)
Specified by:
createEntityManagerFactory in interface javax.persistence.spi.PersistenceProvider

createContainerEntityManagerFactory

public javax.persistence.EntityManagerFactory createContainerEntityManagerFactory(javax.persistence.spi.PersistenceUnitInfo pui,
                                                                                  Map properties)
Specified by:
createContainerEntityManagerFactory in interface javax.persistence.spi.PersistenceProvider

setSpace

public void setSpace(IJSpace space)
Sets the space instance which will be injected to the EntityManagerFactory instance.

Parameters:
space - The space instance to inject.

getProviderUtil

public javax.persistence.spi.ProviderUtil getProviderUtil()
Specified by:
getProviderUtil in interface javax.persistence.spi.PersistenceProvider

GigaSpaces XAP 9.7.2 API

Copyright © GigaSpaces.