public function createInstance(
        $class, $useParameter = false, $jvalue = null
    ) {
        if (isset($this->classMap[$class])) {
            if (is_callable($mapper = $this->classMap[$class])) {
                $class = $mapper($class, $jvalue);
            } else {
                $class = $this->classMap[$class];
            }
        }
        if ($useParameter) {
            return new $class($jvalue);
        } else {
            return (new ReflectionClass($class))->newInstanceWithoutConstructor();
        }
    }