mirror of
https://github.com/itflow-org/itflow
synced 2026-02-28 19:04:52 +00:00
Included WebKlex PHP-IMAP Library in plugins folder to allow for future use when we convert IMAP to allow OAUTH2
This commit is contained in:
28
plugins/php-imap/Events/Event.php
Normal file
28
plugins/php-imap/Events/Event.php
Normal file
@@ -0,0 +1,28 @@
|
||||
<?php
|
||||
/*
|
||||
* File: Event.php
|
||||
* Category: Event
|
||||
* Author: M. Goldenbaum
|
||||
* Created: 25.11.20 22:21
|
||||
* Updated: -
|
||||
*
|
||||
* Description:
|
||||
* -
|
||||
*/
|
||||
|
||||
namespace Webklex\PHPIMAP\Events;
|
||||
|
||||
/**
|
||||
* Class Event
|
||||
*
|
||||
* @package Webklex\PHPIMAP\Events
|
||||
*/
|
||||
abstract class Event {
|
||||
|
||||
/**
|
||||
* Dispatch the event with the given arguments.
|
||||
*/
|
||||
public static function dispatch(): Event {
|
||||
return new static(func_get_args());
|
||||
}
|
||||
}
|
||||
22
plugins/php-imap/Events/FlagDeletedEvent.php
Normal file
22
plugins/php-imap/Events/FlagDeletedEvent.php
Normal file
@@ -0,0 +1,22 @@
|
||||
<?php
|
||||
/*
|
||||
* File: FlagDeletedEvent.php
|
||||
* Category: Event
|
||||
* Author: M. Goldenbaum
|
||||
* Created: 25.11.20 22:21
|
||||
* Updated: -
|
||||
*
|
||||
* Description:
|
||||
* -
|
||||
*/
|
||||
|
||||
namespace Webklex\PHPIMAP\Events;
|
||||
|
||||
/**
|
||||
* Class FlagDeletedEvent
|
||||
*
|
||||
* @package Webklex\PHPIMAP\Events
|
||||
*/
|
||||
class FlagDeletedEvent extends FlagNewEvent {
|
||||
|
||||
}
|
||||
40
plugins/php-imap/Events/FlagNewEvent.php
Normal file
40
plugins/php-imap/Events/FlagNewEvent.php
Normal file
@@ -0,0 +1,40 @@
|
||||
<?php
|
||||
/*
|
||||
* File: FlagNewEvent.php
|
||||
* Category: Event
|
||||
* Author: M. Goldenbaum
|
||||
* Created: 25.11.20 22:21
|
||||
* Updated: -
|
||||
*
|
||||
* Description:
|
||||
* -
|
||||
*/
|
||||
|
||||
namespace Webklex\PHPIMAP\Events;
|
||||
|
||||
use Webklex\PHPIMAP\Message;
|
||||
|
||||
/**
|
||||
* Class FlagNewEvent
|
||||
*
|
||||
* @package Webklex\PHPIMAP\Events
|
||||
*/
|
||||
class FlagNewEvent extends Event {
|
||||
|
||||
/** @var Message $message */
|
||||
public Message $message;
|
||||
|
||||
/** @var string $flag */
|
||||
public string $flag;
|
||||
|
||||
/**
|
||||
* Create a new event instance.
|
||||
* @var array $arguments
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function __construct(array $arguments) {
|
||||
$this->message = $arguments[0];
|
||||
$this->flag = $arguments[1];
|
||||
}
|
||||
}
|
||||
22
plugins/php-imap/Events/FolderDeletedEvent.php
Normal file
22
plugins/php-imap/Events/FolderDeletedEvent.php
Normal file
@@ -0,0 +1,22 @@
|
||||
<?php
|
||||
/*
|
||||
* File: FolderDeletedEvent.php
|
||||
* Category: Event
|
||||
* Author: M. Goldenbaum
|
||||
* Created: 25.11.20 22:21
|
||||
* Updated: -
|
||||
*
|
||||
* Description:
|
||||
* -
|
||||
*/
|
||||
|
||||
namespace Webklex\PHPIMAP\Events;
|
||||
|
||||
/**
|
||||
* Class FolderDeletedEvent
|
||||
*
|
||||
* @package Webklex\PHPIMAP\Events
|
||||
*/
|
||||
class FolderDeletedEvent extends FolderNewEvent {
|
||||
|
||||
}
|
||||
40
plugins/php-imap/Events/FolderMovedEvent.php
Normal file
40
plugins/php-imap/Events/FolderMovedEvent.php
Normal file
@@ -0,0 +1,40 @@
|
||||
<?php
|
||||
/*
|
||||
* File: FolderMovedEvent.php
|
||||
* Category: Event
|
||||
* Author: M. Goldenbaum
|
||||
* Created: 25.11.20 22:21
|
||||
* Updated: -
|
||||
*
|
||||
* Description:
|
||||
* -
|
||||
*/
|
||||
|
||||
namespace Webklex\PHPIMAP\Events;
|
||||
|
||||
use Webklex\PHPIMAP\Folder;
|
||||
|
||||
/**
|
||||
* Class FolderMovedEvent
|
||||
*
|
||||
* @package Webklex\PHPIMAP\Events
|
||||
*/
|
||||
class FolderMovedEvent extends Event {
|
||||
|
||||
/** @var Folder $old_folder */
|
||||
public Folder $old_folder;
|
||||
|
||||
/** @var Folder $new_folder */
|
||||
public Folder $new_folder;
|
||||
|
||||
/**
|
||||
* Create a new event instance.
|
||||
* @var Folder[] $folders
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function __construct(array $folders) {
|
||||
$this->old_folder = $folders[0];
|
||||
$this->new_folder = $folders[1];
|
||||
}
|
||||
}
|
||||
36
plugins/php-imap/Events/FolderNewEvent.php
Normal file
36
plugins/php-imap/Events/FolderNewEvent.php
Normal file
@@ -0,0 +1,36 @@
|
||||
<?php
|
||||
/*
|
||||
* File: FolderNewEvent.php
|
||||
* Category: Event
|
||||
* Author: M. Goldenbaum
|
||||
* Created: 25.11.20 22:21
|
||||
* Updated: -
|
||||
*
|
||||
* Description:
|
||||
* -
|
||||
*/
|
||||
|
||||
namespace Webklex\PHPIMAP\Events;
|
||||
|
||||
use Webklex\PHPIMAP\Folder;
|
||||
|
||||
/**
|
||||
* Class FolderNewEvent
|
||||
*
|
||||
* @package Webklex\PHPIMAP\Events
|
||||
*/
|
||||
class FolderNewEvent extends Event {
|
||||
|
||||
/** @var Folder $folder */
|
||||
public Folder $folder;
|
||||
|
||||
/**
|
||||
* Create a new event instance.
|
||||
* @var Folder[] $folders
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function __construct(array $folders) {
|
||||
$this->folder = $folders[0];
|
||||
}
|
||||
}
|
||||
22
plugins/php-imap/Events/MessageCopiedEvent.php
Normal file
22
plugins/php-imap/Events/MessageCopiedEvent.php
Normal file
@@ -0,0 +1,22 @@
|
||||
<?php
|
||||
/*
|
||||
* File: MessageCopiedEvent.php
|
||||
* Category: Event
|
||||
* Author: M. Goldenbaum
|
||||
* Created: 25.11.20 22:21
|
||||
* Updated: -
|
||||
*
|
||||
* Description:
|
||||
* -
|
||||
*/
|
||||
|
||||
namespace Webklex\PHPIMAP\Events;
|
||||
|
||||
/**
|
||||
* Class MessageCopiedEvent
|
||||
*
|
||||
* @package Webklex\PHPIMAP\Events
|
||||
*/
|
||||
class MessageCopiedEvent extends MessageMovedEvent {
|
||||
|
||||
}
|
||||
22
plugins/php-imap/Events/MessageDeletedEvent.php
Normal file
22
plugins/php-imap/Events/MessageDeletedEvent.php
Normal file
@@ -0,0 +1,22 @@
|
||||
<?php
|
||||
/*
|
||||
* File: MessageDeletedEvent.php
|
||||
* Category: Event
|
||||
* Author: M. Goldenbaum
|
||||
* Created: 25.11.20 22:21
|
||||
* Updated: -
|
||||
*
|
||||
* Description:
|
||||
* -
|
||||
*/
|
||||
|
||||
namespace Webklex\PHPIMAP\Events;
|
||||
|
||||
/**
|
||||
* Class MessageDeletedEvent
|
||||
*
|
||||
* @package Webklex\PHPIMAP\Events
|
||||
*/
|
||||
class MessageDeletedEvent extends MessageNewEvent {
|
||||
|
||||
}
|
||||
40
plugins/php-imap/Events/MessageMovedEvent.php
Normal file
40
plugins/php-imap/Events/MessageMovedEvent.php
Normal file
@@ -0,0 +1,40 @@
|
||||
<?php
|
||||
/*
|
||||
* File: MessageMovedEvent.php
|
||||
* Category: Event
|
||||
* Author: M. Goldenbaum
|
||||
* Created: 25.11.20 22:21
|
||||
* Updated: -
|
||||
*
|
||||
* Description:
|
||||
* -
|
||||
*/
|
||||
|
||||
namespace Webklex\PHPIMAP\Events;
|
||||
|
||||
use Webklex\PHPIMAP\Message;
|
||||
|
||||
/**
|
||||
* Class MessageMovedEvent
|
||||
*
|
||||
* @package Webklex\PHPIMAP\Events
|
||||
*/
|
||||
class MessageMovedEvent extends Event {
|
||||
|
||||
/** @var Message $old_message */
|
||||
public Message $old_message;
|
||||
|
||||
/** @var Message $new_message */
|
||||
public Message $new_message;
|
||||
|
||||
/**
|
||||
* Create a new event instance.
|
||||
* @var Message[] $messages
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function __construct(array $messages) {
|
||||
$this->old_message = $messages[0];
|
||||
$this->new_message = $messages[1];
|
||||
}
|
||||
}
|
||||
36
plugins/php-imap/Events/MessageNewEvent.php
Normal file
36
plugins/php-imap/Events/MessageNewEvent.php
Normal file
@@ -0,0 +1,36 @@
|
||||
<?php
|
||||
/*
|
||||
* File: MessageNewEvent.php
|
||||
* Category: Event
|
||||
* Author: M. Goldenbaum
|
||||
* Created: 25.11.20 22:21
|
||||
* Updated: -
|
||||
*
|
||||
* Description:
|
||||
* -
|
||||
*/
|
||||
|
||||
namespace Webklex\PHPIMAP\Events;
|
||||
|
||||
use Webklex\PHPIMAP\Message;
|
||||
|
||||
/**
|
||||
* Class MessageNewEvent
|
||||
*
|
||||
* @package Webklex\PHPIMAP\Events
|
||||
*/
|
||||
class MessageNewEvent extends Event {
|
||||
|
||||
/** @var Message $message */
|
||||
public Message $message;
|
||||
|
||||
/**
|
||||
* Create a new event instance.
|
||||
* @var Message[] $messages
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function __construct(array $messages) {
|
||||
$this->message = $messages[0];
|
||||
}
|
||||
}
|
||||
22
plugins/php-imap/Events/MessageRestoredEvent.php
Normal file
22
plugins/php-imap/Events/MessageRestoredEvent.php
Normal file
@@ -0,0 +1,22 @@
|
||||
<?php
|
||||
/*
|
||||
* File: MessageRestoredEvent.php
|
||||
* Category: Event
|
||||
* Author: M. Goldenbaum
|
||||
* Created: 25.11.20 22:21
|
||||
* Updated: -
|
||||
*
|
||||
* Description:
|
||||
* -
|
||||
*/
|
||||
|
||||
namespace Webklex\PHPIMAP\Events;
|
||||
|
||||
/**
|
||||
* Class MessageRestoredEvent
|
||||
*
|
||||
* @package Webklex\PHPIMAP\Events
|
||||
*/
|
||||
class MessageRestoredEvent extends MessageNewEvent {
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user