Apache Commons is a collection of reusable java components which extends the official java functionality. These libraries helped me to reduce my code complexity.
Here I am listing down some handy methods that I used in my projects. 1.StringUtilsa) IsEmpty/IsBlank - checks if a String contains text
b) Trim/Strip - removes leading and trailing whitespace
c) Split/Join - splits a String into an array of substrings and vice versa
d) IsAlpha/IsNumeric/IsWhitespace/IsAsciiPrintable - checks the characters in a String
2.BeanUtilsa) copyProperties(Object dest, Object orig) Copy property values from the origin bean to the destination bean for all cases where the property names are the same.
b) describe(Object bean) Return the entire set of properties for which the specified bean provides a read method.
c) populate(Object bean, Map properties) Populate the JavaBeans properties of the specified bean, based on the specified name/value pairs.Read more: Semantic Eyes
QR:
Here I am listing down some handy methods that I used in my projects. 1.StringUtilsa) IsEmpty/IsBlank - checks if a String contains text
b) Trim/Strip - removes leading and trailing whitespace
c) Split/Join - splits a String into an array of substrings and vice versa
d) IsAlpha/IsNumeric/IsWhitespace/IsAsciiPrintable - checks the characters in a String
2.BeanUtilsa) copyProperties(Object dest, Object orig) Copy property values from the origin bean to the destination bean for all cases where the property names are the same.
b) describe(Object bean) Return the entire set of properties for which the specified bean provides a read method.
c) populate(Object bean, Map properties) Populate the JavaBeans properties of the specified bean, based on the specified name/value pairs.Read more: Semantic Eyes
QR: