Skip to content

Commit

Permalink
[core]doc
Browse files Browse the repository at this point in the history
  • Loading branch information
phlppchrtn committed Jan 30, 2024
1 parent 3d0e85c commit 054a653
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions vertigo-core/src/main/java/io/vertigo/core/util/ClassUtil.java
Original file line number Diff line number Diff line change
Expand Up @@ -111,11 +111,12 @@ public static <J> J newInstance(final Constructor<J> constructor, final Object[]
}
}

/**
* Récupère le constructeur sans paramètres.
* @param clazz Classe sur laquelle on recherche le constructeur
* @return Constructeur recherché
*/
/**
* Retrieves the no-arg constructor for the given class.
*
* @param clazz The class to find the constructor for
* @return The no-arg constructor for the class
*/
private static <J> Constructor<J> findConstructor(final Class<J> clazz) {
return findConstructor(clazz, EMPTY_CLAZZ_ARRAY);
}
Expand Down Expand Up @@ -462,7 +463,7 @@ public static String getPropertyName(final Method method) {
.isTrue(Boolean.class.equals(method.getReturnType()) || boolean.class.equals(method.getReturnType()), "une méthode is concerne un boolean : {0}", method);
property = method.getName().substring("is".length());
} else {
throw new IllegalArgumentException("Type de Méthode " + method + " non gérée en tant que propriété");
throw new IllegalArgumentException("Method " + method + " must start with 'get' or 'is' to be considered as a property");
}
//On abaisse la première lettre
return StringUtil.first2LowerCase(property);
Expand Down

0 comments on commit 054a653

Please sign in to comment.