1: <?php
 2: /**
 3:  * The Ingo_Script_Sieve_Action_Stop class represents a stop action.
 4:  *
 5:  * See the enclosed file LICENSE for license information (ASL).  If you
 6:  * did not receive this file, see http://www.horde.org/licenses/apache.
 7:  *
 8:  * @author  Mike Cochrane <mike@graftonhall.co.nz>
 9:  * @package Ingo
10:  */
11: class Ingo_Script_Sieve_Action_Stop extends Ingo_Script_Sieve_Action
12: {
13:     /**
14:      * Returns a script snippet representing this rule and any sub-rules.
15:      *
16:      * @return string  A Sieve script snippet.
17:      */
18:     public function toCode()
19:     {
20:         return 'stop;';
21:     }
22: 
23:     /**
24:      * Checks if the rule parameters are valid.
25:      *
26:      * @return boolean|string  True if this rule is valid, an error message
27:      *                         otherwise.
28:      */
29:     public function check()
30:     {
31:         return true;
32:     }
33: 
34: }
35: