return keyId;
}
private int createNewRelationshipType( String name )
{
RelationshipTypeStore typeStore = getRelationshipTypeStore();
int id = (int) typeStore.nextId();
RelationshipTypeRecord record = new RelationshipTypeRecord( id );
record.setInUse( true );
record.setCreated();
int typeBlockId = (int) typeStore.nextBlockId();
record.setTypeBlock( typeBlockId );
int length = name.length();
char[] chars = new char[length];
name.getChars( 0, length, chars, 0 );
Collection<DynamicRecord> typeRecords =
typeStore.allocateTypeNameRecords( typeBlockId, chars );
for ( DynamicRecord typeRecord : typeRecords )
{
record.addTypeRecord( typeRecord );
}
typeStore.updateRecord( record );
typeHolder.addRelationshipType( name, id );
return id;
}