Changeset 1530

Show
Ignore:
Timestamp:
04/10/08 22:43:13 (1 month ago)
Author:
mikey
Message:

replaced stubSessionException with stubIllegalStateException

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/src/main/php/net/stubbles/ipo/session/stubAbstractSession.php

    r1363 r1530  
    99stubClassLoader::load('net::stubbles::ipo::session::stubSession', 
    1010                      'net::stubbles::ipo::request::stubRequest', 
     11                      'net::stubbles::lang::exceptions::stubIllegalStateException', 
    1112                      'net::stubbles::lang::exceptions::stubRuntimeException' 
    1213); 
     
    142143     * 
    143144     * @return  int 
    144      * @throws  stubSessionException 
     145     * @throws  stubIllegalStateException 
    145146     */ 
    146147    public function getStartTime() 
    147148    { 
    148149        if ($this->isValid() == false) { 
    149             throw new stubSessionException('Session is in an invalid state.'); 
     150            throw new stubIllegalStateException('Session is in an invalid state.'); 
    150151        } 
    151152         
     
    264265     * @param   mixed   $default  optional  return this if no data is associated with $key 
    265266     * @return  mixed 
    266      * @throws  stubSessionException 
     267     * @throws  stubIllegalStateException 
    267268     */ 
    268269    public function getValue($key, $default = null) 
    269270    { 
    270271        if ($this->isValid() == false) { 
    271             throw new stubSessionException('Session is in an invalid state.'); 
     272            throw new stubIllegalStateException('Session is in an invalid state.'); 
    272273        } 
    273274         
     
    306307     * @param   string  $key  key where value is stored under 
    307308     * @return  bool    true if value existed and was removed, else false 
    308      * @throws  stubSessionException 
     309     * @throws  stubIllegalStateException 
    309310     */ 
    310311    public function removeValue($key) 
    311312    { 
    312313        if ($this->isValid() == false) { 
    313             throw new stubSessionException('Session is in an invalid state.'); 
     314            throw new stubIllegalStateException('Session is in an invalid state.'); 
    314315        } 
    315316         
     
    337338     * 
    338339     * @return  array<string> 
    339      * @throws  stubSessionException 
     340     * @throws  stubIllegalStateException 
    340341     */ 
    341342    public function getValueKeys() 
    342343    { 
    343344        if ($this->isValid() == false) { 
    344             throw new stubSessionException('Session is in an invalid state.'); 
     345            throw new stubIllegalStateException('Session is in an invalid state.'); 
    345346        } 
    346347         
  • trunk/src/main/php/net/stubbles/ipo/session/stubSession.php

    r1301 r1530  
    77 * @subpackage  ipo_session 
    88 */ 
    9 stubClassLoader::load('net::stubbles::ipo::session::stubSessionException'); 
    109/** 
    1110 * interface for sessions 
     
    5958     * 
    6059     * @return  int 
    61      * @throws  stubSessionException 
    6260     */ 
    6361    public function getStartTime(); 
     
    129127     * @param   mixed   $default  optional  return this if no data is associated with $key 
    130128     * @return  mixed 
    131      * @throws  stubSessionException 
    132129     */ 
    133130    public function getValue($key, $default = null); 
     
    146143     * @param   string  $name  key where value is stored under 
    147144     * @return  bool    true if value existed and was removed, else false 
    148      * @throws  stubSessionException 
    149145     */ 
    150146    public function removeValue($name); 
     
    154150     * 
    155151     * @return  array<string> 
    156      * @throws  stubSessionException 
    157152     */ 
    158153    public function getValueKeys(); 
  • trunk/src/test/php/net/stubbles/ipo/session/stubAbstractSessionTestCase.php

    r1363 r1530  
    9999     * 
    100100     * @test 
    101      * @expectedException  stubSessionException 
     101     * @expectedException  stubIllegalStateException 
    102102     */ 
    103103    public function invalidGetStartTime() 
     
    112112     * 
    113113     * @test 
    114      * @expectedException  stubSessionException 
     114     * @expectedException  stubIllegalStateException 
    115115     */ 
    116116    public function invalidGetValue() 
     
    125125     * 
    126126     * @test 
    127      * @expectedException  stubSessionException 
     127     * @expectedException  stubIllegalStateException 
    128128     */ 
    129129    public function invalidRemoveValue() 
     
    138138     * 
    139139     * @test 
    140      * @expectedException  stubSessionException 
     140     * @expectedException  stubIllegalStateException 
    141141     */ 
    142142    public function invalidGetValueKeys()