Hibernate ORM CollectionAliases - top ranked examples from Open Source projects

These code examples were ranked by Codota’s semantic indexing as the best open source examples for Hibernate ORM CollectionAliases class.

This code example shows how to use the following methods:getSuffixedElementAliases, getSuffixedIndexAliases
 
	public Object getValue() { 
		return element; 
	} 
 
	public Iterator getDeletes(CollectionPersister persister, boolean indexIsFormula)  
	throws HibernateException { 
		 
		final Type indexType = persister.getIndexType(); 
		HashMap snapshot = (HashMap) getSnapshot(); 
		HashMap deletes = (HashMap) snapshot.clone(); 
		deletes.keySet().removeAll( ( (HashMap) getSnapshot(persister) ).keySet() ); 
		ArrayList deleteList = new ArrayList( deletes.size() ); 
		for ( Object o : deletes.entrySet() ) { 
			Map.Entry me = (Map.Entry) o; 
			final Object object = indexIsFormula ? 
					me.getValue() : 
					( (XmlRepresentableType) indexType ).fromXMLString( (String) me.getKey(), persister.getFactory() ); 
			if ( object != null ) { 
				deleteList.add( object ); 
5
CodeRank
This code example shows how to use the following methods:getSuffixedElementAliases, getSuffixedIdentifierAlias
		} 
		else { 
			return false; 
		} 
	} 
 
	public Object get(int index) {
		read(); 
		return values.get(index);
	} 
 
	public int indexOf(Object o) { 
		read(); 
		return values.indexOf(o);
	} 
 
	public int lastIndexOf(Object o) { 
		read(); 
		return values.lastIndexOf(o);
	} 
4
CodeRank
This code example shows how to use the following methods:getSuffixedElementAliases
	public void initializeFromCache(CollectionPersister persister, Serializable disassembled, Object owner) 
	throws HibernateException { 
 
		Type elementType = persister.getElementType(); 
		Serializable[] cached = (Serializable[]) disassembled; 
		for ( int i=0; i<cached.length; i++ ) { 
			Object object = elementType.assemble( cached[i], getSession(), owner ); 
			Element subelement = element.addElement( persister.getElementNodeName() ); 
			elementType.setToXMLNode( subelement, object, persister.getFactory() ); 
		} 
 
	} 
 
	public Serializable disassemble(CollectionPersister persister) throws HibernateException { 
 
		Type elementType = persister.getElementType(); 
		List elements =  element.elements( persister.getElementNodeName() ); 
		int length = elements.size(); 
		Serializable[] result = new Serializable[length]; 
		for ( int i=0; i<length; i++ ) { 
4
CodeRank
See Code Examples for Hibernate ORM CollectionAliases Methods: