public function create($path = null)
{
if ($this->type === Runtime::UNIT_PROCESS) {
return new ProcessCore($path);
}
if ($this->type === Runtime::UNIT_THREAD) {
return new ThreadCore($path);
}
throw new InstantiationException('Passed undefined core type to create');
}