Package org.hibernate.transform

Examples of org.hibernate.transform.ResultTransformer


  protected String[] getResultRowAliases() {
    return queryReturnAliases;
  }
  @Override
  protected ResultTransformer resolveResultTransformer(ResultTransformer resultTransformer) {
    final ResultTransformer implicitResultTransformer = aggregatedSelectExpression == null
        ? null
        : aggregatedSelectExpression.getResultTransformer();
    return HolderInstantiator.resolveResultTransformer( implicitResultTransformer, resultTransformer );
  }
View Full Code Here


      return results;
    }
  }

  private HolderInstantiator buildHolderInstantiator(ResultTransformer queryLocalResultTransformer) {
    final ResultTransformer implicitResultTransformer = aggregatedSelectExpression == null
        ? null
        : aggregatedSelectExpression.getResultTransformer();
    return HolderInstantiator.getHolderInstantiator(
        implicitResultTransformer,
        queryLocalResultTransformer,
View Full Code Here

  protected long countCriteriaResult( Criteria c) {
    CriteriaImpl impl = (CriteriaImpl) c;

    // 先把Projection、ResultTransformer、OrderBy取出来,清空三者后再执行Count操作
    Projection projection = impl.getProjection();
    ResultTransformer transformer = impl.getResultTransformer();

    List<CriteriaImpl.OrderEntry> orderEntries = null;
    try {
      orderEntries = (List) ReflectionUtils.getFieldValue(impl,"orderEntries");
      ReflectionUtils.setFieldValue(impl, "orderEntries", new ArrayList());
View Full Code Here

          key,
          result
      );
    }

    ResultTransformer resolvedTransformer = resolveResultTransformer( queryParameters.getResultTransformer() );
    if ( resolvedTransformer != null ) {
      result = (
          areResultSetRowsTransformedImmediately() ?
              key.getResultTransformer().retransformResults(
                  result,
View Full Code Here

          key,
          result
      );
    }

    ResultTransformer resolvedTransformer = resolveResultTransformer( queryParameters.getResultTransformer() );
    if ( resolvedTransformer != null ) {
      result = (
          areResultSetRowsTransformedImmediately() ?
              key.getResultTransformer().retransformResults(
                  result,
View Full Code Here

  protected String[] getResultRowAliases() {
    return queryReturnAliases;
  }
  @Override
  protected ResultTransformer resolveResultTransformer(ResultTransformer resultTransformer) {
    final ResultTransformer implicitResultTransformer = aggregatedSelectExpression == null
        ? null
        : aggregatedSelectExpression.getResultTransformer();
    return HolderInstantiator.resolveResultTransformer( implicitResultTransformer, resultTransformer );
  }
View Full Code Here

      return results;
    }
  }

  private HolderInstantiator buildHolderInstantiator(ResultTransformer queryLocalResultTransformer) {
    final ResultTransformer implicitResultTransformer = aggregatedSelectExpression == null
        ? null
        : aggregatedSelectExpression.getResultTransformer();
    return HolderInstantiator.getHolderInstantiator(
        implicitResultTransformer,
        queryLocalResultTransformer,
View Full Code Here

          key,
          result
      );
    }

    ResultTransformer resolvedTransformer = resolveResultTransformer( queryParameters.getResultTransformer() );
    if ( resolvedTransformer != null ) {
      result = (
          areResultSetRowsTransformedImmediately() ?
              key.getResultTransformer().retransformResults(
                  result,
View Full Code Here

    assert transformerMap.size() == 1 : "really messed up";
    Object old = transformerMap.put( transformer, "value" );
    assert old != null && transformerMap.size() == 1 : "apparent QueryKey equals/hashCode issue";

    // finally, lets serialize it and see what happens
    ResultTransformer transformer2 = ( ResultTransformer ) SerializationHelper.clone( transformer );
    old = transformerMap.put( transformer2, "new value" );
    assert old != null && transformerMap.size() == 1 : "deserialization did not set hashCode or equals properly";
    if ( isSingleton ) {
      assert transformer == transformer2: "deserialization issue for singleton transformer";     
    }
View Full Code Here

          key,
          result
      );
    }

    ResultTransformer resolvedTransformer = resolveResultTransformer( queryParameters.getResultTransformer() );
    if ( resolvedTransformer != null ) {
      result = (
          areResultSetRowsTransformedImmediately() ?
              key.getResultTransformer().retransformResults(
                  result,
View Full Code Here

TOP

Related Classes of org.hibernate.transform.ResultTransformer

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.