public boolean isShareable(Class<?> entityClass){
  return getAnnotation(entityClass,SharePermission.class) != null;
}

public boolean isShareable ( Class < ? > entityClass ) { return getAnnotation ( entityClass , SharePermission . class ) != null ; }
returns whether or not an entity is shareable .
