Leo Jiang Leo Jiang - 1 year ago 116
Java Question

How do I use StringUtils in Java?

I'm a beginner in Java. I want to use

but Eclipse outputs
"StringUtils cannot be resolved"

I tried
import java.lang.*;
, but it doesn't work.

Answer Source

java.lang does not contain a class called StringUtils. Several third-party libs do, such as Apache Commons Lang or the Spring framework. Make sure you have the relevant jar in your project classpath and import the correct class.

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download