         validators[message] = condtion
     }
 
+    func validate() -> Bool {
+        validateAllRules()
+        return hasError
+    }
+
 }

    }


    private func setRequiredError () {
        if let fieldName = placeholder {
            title.text = "\(fieldName) can't be blank"

        }, completion: nil)
    }

    private func hideTitle(animated: Bool) {
        let dur = animated ? animationDuration : 0
        UIView.animateWithDuration(dur, delay: 0, options: UIViewAnimationOptions.BeginFromCurrentState | UIViewAnimationOptions.CurveEaseIn, animations: {
            // Animation
