X-Git-Url: http://git.inspyration.org/?a=blobdiff_plain;f=vendor%2Fdoctrine%2Fcommon%2Ftests%2FDoctrine%2FTests%2FCommon%2FAnnotations%2FFixtures%2FClassWithClosure.php;fp=vendor%2Fdoctrine%2Fcommon%2Ftests%2FDoctrine%2FTests%2FCommon%2FAnnotations%2FFixtures%2FClassWithClosure.php;h=4629507dd333c34cd74423a7c48f0bf25c72fb2f;hb=8b04b2d11798dee4f3e1358e4f43e97a6df851f6;hp=0000000000000000000000000000000000000000;hpb=73568cf05a785a45f94ca3f2351d9e07bf917958;p=zf2.biz%2Fapplication_blanche.git diff --git a/vendor/doctrine/common/tests/Doctrine/Tests/Common/Annotations/Fixtures/ClassWithClosure.php b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Annotations/Fixtures/ClassWithClosure.php new file mode 100644 index 0000000..4629507 --- /dev/null +++ b/vendor/doctrine/common/tests/Doctrine/Tests/Common/Annotations/Fixtures/ClassWithClosure.php @@ -0,0 +1,52 @@ +events->filter(function ($item) use ($year, $month, $day) { + $leftDate = new \DateTime($year.'-'.$month.'-'.$day.' 00:00'); + $rigthDate = new \DateTime($year.'-'.$month.'-'.$day.' +1 day 00:00'); + return ( ( $leftDate <= $item->getDateStart() ) && ( $item->getDateStart() < $rigthDate ) ); + + } + ); + return $extractEvents; + } + +} \ No newline at end of file