add some validate methods.