public function getFunctionArguments($class, $method) {

        $ReflectionMethod = new \ReflectionMethod($class, $method);

        $paramsArray = array();
        foreach ($ReflectionMethod->getParameters() as $param) {
            $auxParam = array('name' => $param->getName(), 'isOptional' => false, 'initialValue' => null);
            if ($param->isOptional()) {
                $auxParam['isOptional'] = true;
                $auxParam['initialValue'] = $param->getDefaultValue();
            }
            $paramsArray[] = $auxParam;
        }
        return $paramsArray;
    }