Use {@link attachTo()} to attach a resource to a repository. The method
{@link detach()} can be used to detach an attached resource.
public getRepository ( ) : Puli\Repository\Api\ResourceRepository | null | ||
return | Puli\Repository\Api\ResourceRepository | null | The resource repository. If the resource is not attached to any repository, `null` is returned. |