Examples of EntityReference


Examples of fr.adrienbrault.idea.symfony2plugin.doctrine.EntityReference

                            psiReferences.add(assistantReferenceProvider.getPsiReference(psiElement, null));
                        }
                    } */

                    if(phpDocParamTag.getTagValue().contains("#Entity")) {
                        psiReferences.add(new EntityReference(psiElement));
                    }

                    if(phpDocParamTag.getTagValue().contains("#Service")) {
                        psiReferences.add(new ServiceReference(psiElement));
                    }
View Full Code Here

Examples of hu.jokeman.xparser.cldc11.document.nodes.EntityReference

    public void addEntityReference (String entityName)
            throws DocumentBuilderException {
        XMLNode currentNode = peek ();
        if (currentNode instanceof Element) {
            currentNode.addChild (new EntityReference (entityName));
        } else {
            throw new DocumentBuilderException (
                    "Entity references not allowed here.");
        }
    }
View Full Code Here

Examples of hu.jokeman.xparser.impl.document.nodes.EntityReference

    public void addEntityReference (String entityName)
            throws DocumentBuilderException {
        XMLNode currentNode = peek ();
        if (currentNode instanceof Element) {
            currentNode.addChild (new EntityReference (entityName));
        } else {
            throw new DocumentBuilderException (
                    "Entity references not allowed here.");
        }
    }
View Full Code Here

Examples of javax.xml.stream.events.EntityReference

              case XMLStreamConstants.COMMENT:
                  element.addContent(new Comment(currentEvent.asCharacters().getData()));
                  break;
 
              case XMLStreamConstants.ENTITY_REFERENCE:
                EntityReference er = (EntityReference)currentEvent;
                  element.addContent(new EntityRef(er.getName(), er.getDeclaration().getPublicId(), er.getDeclaration().getSystemId()));
                break;
 
              case XMLStreamConstants.PROCESSING_INSTRUCTION:
                javax.xml.stream.events.ProcessingInstruction pi = (javax.xml.stream.events.ProcessingInstruction)currentEvent;
                  element.addContent(new ProcessingInstruction(pi.getTarget(), pi.getData()));
View Full Code Here

Examples of mf.org.w3c.dom.EntityReference

        if (!fDeferNodeExpansion) {
            if (fFilterReject) {
                return;
            }
            setCharacterData (true);
            EntityReference er = fDocument.createEntityReference (name);
            if (fDocumentImpl != null) {
                // REVISIT: baseURI/actualEncoding
                //         remove dependency on our implementation when DOM L3 is REC
                //
View Full Code Here

Examples of org.hibernate.loader.plan.spi.EntityReference

    final CollectionFetchableIndex indexGraph = collectionReference.getIndexGraph();
    if ( indexGraph != null ) {
      printWriter.print( TreePrinterHelper.INSTANCE.generateNodePrefix( depth ) + "(collection index) " );

      if ( EntityReference.class.isInstance( indexGraph ) ) {
        final EntityReference indexGraphAsEntityReference = (EntityReference) indexGraph;
        printWriter.println( extractDetails( indexGraphAsEntityReference ) );
        writeEntityReferenceFetches( indexGraphAsEntityReference, depth+1, printWriter );
      }
      else if ( CompositeFetch.class.isInstance( indexGraph ) ) {
        final CompositeFetch indexGraphAsCompositeFetch = (CompositeFetch) indexGraph;
        printWriter.println( extractDetails( indexGraphAsCompositeFetch ) );
        writeCompositeFetchFetches( indexGraphAsCompositeFetch, depth+1, printWriter );
      }
    }

    final CollectionFetchableElement elementGraph = collectionReference.getElementGraph();
    if ( elementGraph != null ) {
      printWriter.print( TreePrinterHelper.INSTANCE.generateNodePrefix( depth ) + "(collection element) " );

      if ( EntityReference.class.isInstance( elementGraph ) ) {
        final EntityReference elementGraphAsEntityReference = (EntityReference) elementGraph;
        printWriter.println( extractDetails( elementGraphAsEntityReference ) );
        writeEntityReferenceFetches( elementGraphAsEntityReference, depth+1, printWriter );
      }
      else if ( CompositeFetch.class.isInstance( elementGraph ) ) {
        final CompositeFetch elementGraphAsCompositeFetch = (CompositeFetch) elementGraph;
View Full Code Here

Examples of org.hibernate.loader.plan.spi.EntityReference

              fetchSource
          )
      );
    }

    final EntityReference entityReference = (EntityReference) fetchSource;
    // NOTE : this is not the most exhaustive of checks because of hierarchical associations (employee/manager)
    if ( ! entityReference.getEntityPersister().equals( entityDefinition.getEntityPersister() ) ) {
      throw new WalkingException( "Mismatched FetchSource from stack on pop" );
    }
  }
View Full Code Here

Examples of org.hibernate.loader.plan.spi.EntityReference

        "%s Starting entity identifier : %s",
        StringHelper.repeat( ">>", fetchSourceStack.size() ),
        entityIdentifierDefinition.getEntityDefinition().getEntityPersister().getEntityName()
    );

    final EntityReference entityReference = (EntityReference) currentSource();

    // perform some stack validation
    if ( ! entityReference.getEntityPersister().equals( entityIdentifierDefinition.getEntityDefinition().getEntityPersister() ) ) {
      throw new WalkingException(
          String.format(
              "Encountered unexpected fetch owner [%s] in stack while processing entity identifier for [%s]",
              entityReference.getEntityPersister().getEntityName(),
              entityIdentifierDefinition.getEntityDefinition().getEntityPersister().getEntityName()
          )
      );
    }

    if ( ExpandingEntityIdentifierDescription.class.isInstance( entityReference.getIdentifierDescription() ) ) {
      pushToStack( (ExpandingEntityIdentifierDescription) entityReference.getIdentifierDescription() );
    }
  }
View Full Code Here

Examples of org.hibernate.loader.plan.spi.EntityReference

    if ( ! ExpandingEntityIdentifierDescription.class.isInstance( currentSource ) ) {
      // in this case, the current source should be the entity that owns entityIdentifierDefinition
      if ( ! EntityReference.class.isInstance( currentSource ) ) {
        throw new WalkingException( "Unexpected state in FetchSource stack" );
      }
      final EntityReference entityReference = (EntityReference) currentSource;
      if ( entityReference.getEntityPersister().getEntityKeyDefinition() != entityIdentifierDefinition ) {
        throw new WalkingException(
            String.format(
                "Encountered unexpected fetch owner [%s] in stack while processing entity identifier for [%s]",
                entityReference.getEntityPersister().getEntityName(),
                entityIdentifierDefinition.getEntityDefinition().getEntityPersister().getEntityName()
            )
        );
      }
      return;
    }

    // the current source is ExpandingEntityIdentifierDescription...
    final ExpandingEntityIdentifierDescription identifierDescription =
        (ExpandingEntityIdentifierDescription) popFromStack();

    // and then on the node before it (which should be the entity that owns the identifier being described)
    final ExpandingFetchSource entitySource = currentSource();
    if ( ! EntityReference.class.isInstance( entitySource ) ) {
      throw new WalkingException( "Unexpected state in FetchSource stack" );
    }
    final EntityReference entityReference = (EntityReference) entitySource;
    if ( entityReference.getIdentifierDescription() != identifierDescription ) {
      throw new WalkingException(
          String.format(
              "Encountered unexpected fetch owner [%s] in stack while processing entity identifier for [%s]",
              entityReference.getEntityPersister().getEntityName(),
              entityIdentifierDefinition.getEntityDefinition().getEntityPersister().getEntityName()
          )
      );
    }
View Full Code Here

Examples of org.hibernate.loader.plan.spi.EntityReference

    this.readerCollector = new CollectionLoaderReaderCollectorImpl(
        new CollectionReturnReader( rootReturn ),
        new CollectionReferenceInitializerImpl( rootReturn, collectionReferenceAliases )
    );
    if ( rootReturn.getCollectionPersister().getElementType().isEntityType() ) {
      final EntityReference elementEntityReference = rootReturn.getElementGraph().resolveEntityReference();
      readerCollector.add(
        new EntityReferenceInitializerImpl( elementEntityReference, collectionReferenceAliases.getEntityElementAliases() )
      );
    }
    if ( rootReturn.getCollectionPersister().hasIndex() &&
        rootReturn.getCollectionPersister().getIndexType().isEntityType() ) {
      final EntityReference indexEntityReference = rootReturn.getIndexGraph().resolveEntityReference();
      final EntityReferenceAliases indexEntityReferenceAliases = aliasResolutionContext.generateEntityReferenceAliases(
          indexEntityReference.getQuerySpaceUid(),
          indexEntityReference.getEntityPersister()
      );
      readerCollector.add(
          new EntityReferenceInitializerImpl( indexEntityReference, indexEntityReferenceAliases )
      );
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.