public static AssociationAttribute < ? > createEmptyAssociationAttribute ( AssociationAttributeInfo info ) { AssociationAttribute < ? > association ; switch ( info . getType ( ) ) { case MANY_TO_ONE : association = new ManyToOneAttribute ( ) ; break ; case ONE_TO_MANY : association = new OneToManyAttribute ( ) ; break ; default : String msg = "Trying to build an unknown association attribute type " + info . getType ( ) ; Log . logError ( msg ) ; throw new IllegalStateException ( msg ) ; } association . setEditable ( info . isEditable ( ) ) ; return association ; }
Creates an empty association attribute . An empty attribute is an attribute which has null as its value .