Examples of disassemble()


Examples of org.hibernate.type.Type.disassemble()

    Serializable[] result = new Serializable[length];
    for ( int i=0; i<length; i++ ) {
      Element elem = (Element) elements.get(i);
      Object object = elementType.fromXMLNode( elem, persister.getFactory() );
      Integer index = IntegerType.INSTANCE.fromString( getIndex(elem, indexNodeName, i) );
      result[ index.intValue() ] = elementType.disassemble( object, getSession(), null );
    }
    return result;
  }

View Full Code Here

Examples of org.hibernate.type.Type.disassemble()

    int length = elements.size();
    Serializable[] result = new Serializable[length];
    for ( int i=0; i<length; i++ ) {
      Element elem = (Element) elements.get(i);
      Object object = elementType.fromXMLNode( elem, persister.getFactory() );
      result[i] = elementType.disassemble( object, getSession(), null );
    }
    return result;
  }

  @Override
View Full Code Here

Examples of org.hibernate.type.Type.disassemble()

            final Type type = propertyTypes[naturalIdPropertyIndex];
      final Object value = naturalIdValues[i];
     
      result = prime * result + (value != null ? type.getHashCode( value, factory ) : 0);
     
      this.naturalIdValues[i] = type.disassemble( value, session, null );
    }
   
    this.hashCode = result;
    initTransients();
  }
View Full Code Here

Examples of org.hibernate.type.Type.disassemble()

    int length = elements.size();
    Serializable[] result = new Serializable[length];
    for ( int i=0; i<length; i++ ) {
      Element elem = (Element) elements.get(i);
      Object object = elementType.fromXMLNode( elem, persister.getFactory() );
      result[i] = elementType.disassemble( object, getSession(), null );
    }
    return result;
  }

  @Override
View Full Code Here

Examples of org.hibernate.type.Type.disassemble()

      // TODO: The snapshot should probably be revisited at some point.  Consider semi-resolving, hydrating, etc.
      if (type instanceof EntityType && type.getSemiResolvedType( factory ).getReturnedClass().isInstance( value )) {
        this.naturalIdValues[i] = (Serializable) value;
      }
      else {
        this.naturalIdValues[i] = type.disassemble( value, session, null );
      }
    }
   
    this.hashCode = result;
    initTransients();
View Full Code Here

Examples of org.hibernate.type.Type.disassemble()

    Serializable[] result = new Serializable[length];
    for ( int i=0; i<length; i++ ) {
      Element elem = (Element) elements.get(i);
      Object object = elementType.fromXMLNode( elem, persister.getFactory() );
      Integer index = IntegerType.INSTANCE.fromString( getIndex(elem, indexNodeName, i) );
      result[index] = elementType.disassemble( object, getSession(), null );
    }
    return result;
  }

View Full Code Here

Examples of org.hibernate.type.Type.disassemble()

      final Type type = propertyTypes[naturalIdPropertyIndex];
      final Object value = naturalIdValues[i];

      result = prime * result + (value != null ? type.getHashCode( value, factory ) : 0);

      this.naturalIdValues[i] = type.disassemble( value, session, null );
    }

    this.hashCode = result;
    initTransients();
  }
View Full Code Here

Examples of org.hibernate.type.Type.disassemble()

    final int length = elements.size();
    final Serializable[] result = new Serializable[length];
    for ( int i=0; i<length; i++ ) {
      final Element elem = (Element) elements.get( i );
      final Object object = collectionElementType.fromXMLNode( elem, persister.getFactory() );
      result[i] = collectionElementType.disassemble( object, getSession(), null );
    }
    return result;
  }

  @Override
View Full Code Here

Examples of org.hibernate.type.Type.disassemble()

    final Serializable[] result = new Serializable[length];
    for ( int i=0; i<length; i++ ) {
      final Element elem = (Element) elements.get( i );
      final Object object = elementType.fromXMLNode( elem, persister.getFactory() );
      final Integer index = IntegerType.INSTANCE.fromString( getIndex( elem, indexNodeName, i ) );
      result[index] = elementType.disassemble( object, getSession(), null );
    }
    return result;
  }

View Full Code Here

Examples of org.hibernate.type.Type.disassemble()

    while ( i < length*2 ) {
      final Element elem = (Element) elements.get( i/2 );
      final Object object = elementType.fromXMLNode( elem, persister.getFactory() );
      final String indexString = getIndex( elem, indexNodeName, i );
      final Object index = ( (XmlRepresentableType) indexType ).fromXMLString( indexString, persister.getFactory() );
      result[i++] = indexType.disassemble( index, getSession(), null );
      result[i++] = elementType.disassemble( object, getSession(), null );
    }
    return result;
  }
}
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.