private void bindEntityId(Class<?> cls,String type,AccessibleObject fieldOrMethod){
  String fieldName=getFieldName(fieldOrMethod);
  Class<?> fieldType=getFieldType(fieldOrMethod);
  fieldsToTypes.put(fieldName,fieldType);
  idField=fieldOrMethod;
  idType=fieldType;
  idFieldName=fieldName;
  fieldsToValues.put(fieldName,fieldOrMethod);
  if (idField != null && !fieldOrMethod.equals(idField)) {
    throw new DuplicateMappingException(type + " " + cls.getName()+ ":"+ fieldName);
  }
}

private void bindEntityId ( Class < ? > cls , String type , AccessibleObject fieldOrMethod ) { String fieldName = getFieldName ( fieldOrMethod ) ; Class < ? > fieldType = getFieldType ( fieldOrMethod ) ; fieldsToTypes . put ( fieldName , fieldType ) ; idField = fieldOrMethod ; idType = fieldType ; idFieldName = fieldName ; fieldsToValues . put ( fieldName , fieldOrMethod ) ; if ( idField != null && ! fieldOrMethod . equals ( idField ) ) { throw new DuplicateMappingException ( type + " " + cls . getName ( ) + ":" + fieldName ) ; } }
bind an id field to an entity .
