public function addType($type)
{
if (func_num_args() > 1) {
foreach (func_get_args() as $t) {
$this->addType($t);
}
} else {
if (is_array($type)) {
foreach ($type as $t) {
$this->addType($t);
}
} else {
if (!$this->typeIsAvailable($type)) {
$this->types[] = $type;
}
}
}
return $this;
}