Package org.hibernate.loader.custom.sql

Examples of org.hibernate.loader.custom.sql.SQLQueryReturnProcessor


    LOG.tracev( "Starting processing of NoSQL query [{0}]", queryString );

    this.queryString = queryString;
    this.queryObject = query;

    SQLQueryReturnProcessor processor = new SQLQueryReturnProcessor( queryReturns, factory );
    processor.process();
    customQueryReturns = Collections.unmodifiableList( processor.generateCustomReturns( false ) );

    if ( querySpaces != null ) {
      this.querySpaces = Collections.<String>unmodifiableSet( querySpaces );
    }
    else {
View Full Code Here


    LOG.tracev( "Starting processing of NoSQL query [{0}]", queryString );

    this.queryString = queryString;
    this.queryObject = query;

    SQLQueryReturnProcessor processor = new SQLQueryReturnProcessor( queryReturns, factory );
    processor.process();
    customQueryReturns = Collections.unmodifiableList( processor.generateCustomReturns( false ) );

    if ( querySpaces != null ) {
      this.querySpaces = Collections.<String>unmodifiableSet( querySpaces );
    }
    else {
View Full Code Here

  // Hooks into Hibernate's Loader hierarchy for ResultSet -> Object mapping

  private static CustomLoaderExtension buildSpecializedCustomLoader(final ResultContext context) {
    // might be better to just manually construct the Return(s).. SQLQueryReturnProcessor does a lot of
    // work that is really unnecessary here.
    final SQLQueryReturnProcessor processor = new SQLQueryReturnProcessor(
        context.getQueryReturns(),
        context.getSession().getFactory()
    );
    processor.process();
    final List<org.hibernate.loader.custom.Return> customReturns = processor.generateCustomReturns( false );

    CustomQuery customQuery = new CustomQuery() {
      @Override
      public String getSQL() {
        return context.getSql();
View Full Code Here

      log.tracef( "Found result-set-mapping : %s", mapping.traceLoggableFormat() );

      context.addQueryReturns( mapping.getQueryReturns() );

      final SQLQueryReturnProcessor processor =
          new SQLQueryReturnProcessor( mapping.getQueryReturns(), context.getSessionFactory() );
      final SQLQueryReturnProcessor.ResultAliasContext processResult = processor.process();
      context.addQuerySpaces( processResult.collectQuerySpaces() );
    }
  }
View Full Code Here

    this.queryString = spec.getQueryString();
    this.queryObject = spec.getQueryObject();
    this.sessionFactory = factory;

    SQLQueryReturnProcessor processor = new SQLQueryReturnProcessor(spec.getQueryReturns(), factory);
    processor.process();
    customQueryReturns = Collections.unmodifiableList( processor.generateCustomReturns( false ) );

    if ( spec.getQuerySpaces() != null ) {
      @SuppressWarnings("unchecked")
      Set<String> spaces = spec.getQuerySpaces();
      querySpaces = Collections.<String>unmodifiableSet( spaces );
View Full Code Here

  // Hooks into Hibernate's Loader hierarchy for ResultSet -> Object mapping

  private static CustomLoaderExtension buildSpecializedCustomLoader(final ResultContext context) {
    // might be better to just manually construct the Return(s).. SQLQueryReturnProcessor does a lot of
    // work that is really unnecessary here.
    final SQLQueryReturnProcessor processor = new SQLQueryReturnProcessor(
        context.getQueryReturns(),
        context.getSession().getFactory()
    );
    processor.process();
    final List<org.hibernate.loader.custom.Return> customReturns = processor.generateCustomReturns( false );

    CustomQuery customQuery = new CustomQuery() {
      @Override
      public String getSQL() {
        return context.getSql();
View Full Code Here

    this.queryString = spec.getQueryString();
    this.queryObject = spec.getQueryObject();
    this.sessionFactory = factory;

    SQLQueryReturnProcessor processor = new SQLQueryReturnProcessor(spec.getQueryReturns(), factory);
    processor.process();
    customQueryReturns = Collections.unmodifiableList( processor.generateCustomReturns( false ) );

    if ( spec.getQuerySpaces() != null ) {
      @SuppressWarnings("unchecked")
      Set<String> spaces = spec.getQuerySpaces();
      querySpaces = Collections.<String>unmodifiableSet( spaces );
View Full Code Here

  // Hooks into Hibernate's Loader hierarchy for ResultSet -> Object mapping

  private static CustomLoaderExtension buildSpecializedCustomLoader(final ResultContext context) {
    // might be better to just manually construct the Return(s).. SQLQueryReturnProcessor does a lot of
    // work that is really unnecessary here.
    final SQLQueryReturnProcessor processor = new SQLQueryReturnProcessor(
        context.getQueryReturns(),
        context.getSession().getFactory()
    );
    processor.process();
    final List<org.hibernate.loader.custom.Return> customReturns = processor.generateCustomReturns( false );

    CustomQuery customQuery = new CustomQuery() {
      @Override
      public String getSQL() {
        return context.getSql();
View Full Code Here

      log.tracef( "Found result-set-mapping : %s", mapping.traceLoggableFormat() );

      context.addQueryReturns( mapping.getQueryReturns() );

      final SQLQueryReturnProcessor processor =
          new SQLQueryReturnProcessor( mapping.getQueryReturns(), context.getSessionFactory() );
      final SQLQueryReturnProcessor.ResultAliasContext processResult = processor.process();
      context.addQuerySpaces( processResult.collectQuerySpaces() );
    }
  }
View Full Code Here

      return false;
    }
  }

  private static CustomLoaderExtension buildSpecializedCustomLoader(final ResultContext context) {
    final SQLQueryReturnProcessor processor = new SQLQueryReturnProcessor(
        context.getQueryReturns(),
        context.getSession().getFactory()
    );
    processor.process();
    final List<org.hibernate.loader.custom.Return> customReturns = processor.generateCustomReturns( false );

    CustomQuery customQuery = new CustomQuery() {
      @Override
      public String getSQL() {
        return context.getSql();
View Full Code Here

TOP

Related Classes of org.hibernate.loader.custom.sql.SQLQueryReturnProcessor

Copyright © 2018 www.massapicom. 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.