File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Refactoring validations

 
Wilker Iceri
Greenhorn
Posts: 1
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello!

I have two classes for example:



I have two different objects(obj and obj2) with attribute email. Currently i use a method statis ValidatorUtil.isValidString()... for validate strings, etc.

What is the best way for encapsulate the validation? For i remove this from the login methods?

Thanks, and sorry for bad english
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic