From 36938bba6613c65667306d1a851910bfa113ebdf Mon Sep 17 00:00:00 2001 From: Simon Vieille Date: Sun, 22 May 2016 23:39:06 +0200 Subject: [PATCH] README --- README.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/README.md b/README.md index 88814ce..3a07c82 100644 --- a/README.md +++ b/README.md @@ -42,6 +42,9 @@ $validator->addFieldConstraint(0, new Email()); // The second field must contain a date $validator->addFieldConstraint(1, new Date()); +// Validate the legend +$validator->setExceptedLegend(array('foo', 'bar', 'bim')); + // An line must contain 3 columns $validator->addDataConstraint(new Callback(function($data, ExecutionContextInterface $context) { if (count($data) !== 6) { // 6 because of the legend (3 fields * 2)