diff options
author | Julius Härtl <jus@bitgrid.net> | 2020-08-21 16:48:15 +0300 |
---|---|---|
committer | Julius Härtl <jus@bitgrid.net> | 2020-10-13 15:36:52 +0300 |
commit | eff8898bd86fc306775fe0e68c66c9a8f82cda0a (patch) | |
tree | 34706ec348bc0044a2950898b446d1d3c61aef1d /lib/Events | |
parent | cc164ab38817c0897ecb62634e3d8eb287757196 (diff) |
Dispatch event to allow change of the redirect url
Signed-off-by: Julius Härtl <jus@bitgrid.net>
Diffstat (limited to 'lib/Events')
-rw-r--r-- | lib/Events/BeforeFederationRedirectEvent.php | 46 |
1 files changed, 46 insertions, 0 deletions
diff --git a/lib/Events/BeforeFederationRedirectEvent.php b/lib/Events/BeforeFederationRedirectEvent.php new file mode 100644 index 00000000..40bb8b02 --- /dev/null +++ b/lib/Events/BeforeFederationRedirectEvent.php @@ -0,0 +1,46 @@ +<?php + +namespace OCA\Richdocuments\Events; + + +use OCP\Files\Node; +use Symfony\Component\EventDispatcher\Event; + +class BeforeFederationRedirectEvent extends Event { + + /** @var Node */ + private $node; + /** @var string */ + private $relativePath; + /** @var string|null */ + private $redirectUrl = null; + /** @var string */ + private $remote; + + public function __construct($node, $relativePath, $remote) { + $this->node = $node; + $this->relativePath = $relativePath; + $this->remote = $remote; + } + + public function getRelativePath() { + return $this->relativePath; + } + + public function getNode() { + return $this->node; + } + + public function getRemote() { + return $this->remote; + } + + public function setRedirectUrl($redirectUrl) { + $this->redirectUrl = $redirectUrl; + } + + public function getRedirectUrl() { + return $this->redirectUrl; + } + +}
\ No newline at end of file |