{% if namespace %}
namespace {{ namespace }};
{% endif %}

use Sdkgen\Client\ResourceAbstract;

class {{ className }} extends ResourceAbstract
{
{% for className, resource in resources %}
    /**
     * {{ resource.description|raw }}
     */
    public function {{ resource.methodName }}({% for name, arg in resource.properties %}{{ arg.type }} ${{ name }}{% if not loop.last %}, {% endif %}{% endfor %}): {{ className }}
    {
        return new {{ className }}(
            {% for name, arg in resource.properties %}${{ name }},
            {% endfor %}
$this->baseUrl,
            $this->httpClient,
            $this->schemaManager
        );
    }

{% endfor %}
}
