Guest User

Untitled

a guest
Oct 22nd, 2017
80
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.49 KB | None | 0 0
  1. import org.slf4j.Logger;
  2. import org.slf4j.LoggerFactory;
  3.  
  4. public class ExampleWithLogs {
  5. private static Logger log = LoggerFactory.getLogger(ExampleWithLogs.class);
  6.  
  7. public String getNormalizedName(Person person) {
  8. log.info("getNormalizedName called");
  9. log.debug("Normalizing " + person.toString());
  10. String normalizedName =
  11. person.getName().toUpperCase().trim();
  12. log.debug("Normalized name is: " + normalizedName);
  13. return normalizedName;
  14. }
  15. }
Add Comment
Please, Sign In to add comment