public function beforeUnbind($path)
    {
        // FIXME: We shouldn't trigger this functionality when we're issuing a
        // MOVE. This is a hack.
        if ('MOVE' === $this->server->httpRequest->getMethod()) {
            return;
        }

        $node = $this->server->tree->getNodeForPath($path);

        if (!$node instanceof ICalendarObject || $node instanceof ISchedulingObject) {
            return;
        }

        if (!$this->scheduleReply($this->server->httpRequest)) {
            return;
        }

        $addresses = $this->getAddressesForPrincipal(
            $node->getOwner()
        );

        $broker = new ITip\Broker();
        $messages = $broker->parseEvent(null, $addresses, $node->get());

        foreach ($messages as $message) {
            $this->deliver($message);
        }
    }
public function beforeUnbind($path)
    {
        // FIXME: We shouldn't trigger this functionality when we're issuing a
        // MOVE. This is a hack.
        if ('MOVE' === $this->server->httpRequest->getMethod()) {
            return;
        }

        $node = $this->server->tree->getNodeForPath($path);

        if (!$node instanceof ICalendarObject || $node instanceof ISchedulingObject) {
            return;
        }

        if (!$this->scheduleReply($this->server->httpRequest)) {
            return;
        }

        $addresses = $this->getAddressesForPrincipal(
            $node->getOwner()
        );

        $broker = new ITip\Broker();
        $messages = $broker->parseEvent(null, $addresses, $node->get());

        foreach ($messages as $message) {
            $this->deliver($message);
        }
    }
public function beforeUnbind ( $ path ) { // FIXME: We shouldn't trigger this functionality when we're issuing a // MOVE. This is a hack. if ( 'MOVE' === $ this -> server -> httpRequest -> getMethod ( ) ) { return ; } $ node = $ this -> server -> tree -> getNodeForPath ( $ path ) ; if ( ! $ node instanceof ICalendarObject || $ node instanceof ISchedulingObject ) { return ; } if ( ! $ this -> scheduleReply ( $ this -> server -> httpRequest ) ) { return ; } $ addresses = $ this -> getAddressesForPrincipal ( $ node -> getOwner ( ) ) ; $ broker = new ITip \ Broker ( ) ; $ messages = $ broker -> parseEvent ( null , $ addresses , $ node -> get ( ) ) ; foreach ( $ messages as $ message ) { $ this -> deliver ( $ message ) ; } }
This method is triggered before a file gets deleted.

We use this event to make sure that when this happens, attendees get
cancellations, and organizers get 'DECLINED' statuses.

@param string $path
This method is triggered before a file gets deleted .