First commit
This commit is contained in:
commit
c6e2478c40
13918 changed files with 2303184 additions and 0 deletions
27
vendor/consolidation/annotated-command/src/AnnotationData.php
vendored
Normal file
27
vendor/consolidation/annotated-command/src/AnnotationData.php
vendored
Normal file
|
@ -0,0 +1,27 @@
|
|||
<?php
|
||||
namespace Consolidation\AnnotatedCommand;
|
||||
|
||||
use Consolidation\AnnotatedCommand\Parser\Internal\CsvUtils;
|
||||
|
||||
class AnnotationData extends \ArrayObject
|
||||
{
|
||||
public function get($key, $default = '')
|
||||
{
|
||||
return $this->has($key) ? CsvUtils::toString($this[$key]) : $default;
|
||||
}
|
||||
|
||||
public function getList($key, $default = [])
|
||||
{
|
||||
return $this->has($key) ? CsvUtils::toList($this[$key]) : $default;
|
||||
}
|
||||
|
||||
public function has($key)
|
||||
{
|
||||
return isset($this[$key]);
|
||||
}
|
||||
|
||||
public function keys()
|
||||
{
|
||||
return array_keys($this->getArrayCopy());
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue