public function getProperties($alsoProtected = true, $alsoPrivate = true, $alsoHerited = false)
    {
        $ar = parent::getProperties();
        $this->properties = array();
        foreach ($ar as $property) {
            if ((!$property->isPrivate() || $alsoPrivate) && (!$property->isProtected() || $alsoProtected) && (($property->getDeclaringClass()->name == $this->classname) || $alsoHerited)) {
                try {
                    $p = new IPReflectionProperty($this->classname, $property->getName());
                    $this->properties[$property->name] = $p;
                } catch (ReflectionException $exception) {
                    echo 'Fout bij property: '.$property->name."<br>\n";
                }
            }
        }
        ksort($this->properties);

        return $this->properties;
    }