private synchronized EntityManager getOrCreateProxy(
final AnnotationProvider annotationProvider, final ObjectLocator objectLocator)
{
if (proxy == null)
{
final PlasticProxyFactory proxyFactory = objectLocator.getService("PlasticProxyFactory",
PlasticProxyFactory.class);
final PersistenceContext annotation = annotationProvider
.getAnnotation(PersistenceContext.class);
proxy = proxyFactory.createProxy(EntityManager.class, new ObjectCreator()
{
public Object createObject()
{
final EntityManagerManager entityManagerManager = objectLocator
.getService(EntityManagerManager.class);