update v1.0.3.3

This commit is contained in:
sujitprasad
2015-12-22 14:09:23 +05:30
parent 2bc3db252e
commit 696e0390fe
8590 changed files with 3456 additions and 818 deletions

View File

@@ -0,0 +1,30 @@
<?php
namespace Cron;
/**
* Minutes field. Allows: * , / -
*/
class MinutesField extends AbstractField
{
public function isSatisfiedBy(\DateTime $date, $value)
{
return $this->isSatisfied($date->format('i'), $value);
}
public function increment(\DateTime $date, $invert = false)
{
if ($invert) {
$date->modify('-1 minute');
} else {
$date->modify('+1 minute');
}
return $this;
}
public function validate($value)
{
return (bool) preg_match('/^[\*,\/\-0-9]+$/', $value);
}
}