Changeset 432

Show
Ignore:
Timestamp:
03/28/07 23:27:35 (1 year ago)
Author:
mikey
Message:

moved annotation related stuff into new subpackage net.stubbles.reflection.annotations

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/src/main/php/net/stubbles/rdbms/persistence/annotations/stubDBColumnAnnotation.php

    r333 r432  
    77 * @subpackage  rdbms_persistence_annotations 
    88 */ 
    9 stubClassLoader::load('net.stubbles.reflection.stubAnnotation', 
    10                       'net.stubbles.reflection.stubAbstractAnnotation' 
     9stubClassLoader::load('net.stubbles.reflection.annotations.stubAnnotation', 
     10                      'net.stubbles.reflection.annotations.stubAbstractAnnotation' 
    1111); 
    1212/** 
  • trunk/src/main/php/net/stubbles/rdbms/persistence/annotations/stubDBTableAnnotation.php

    r246 r432  
    77 * @subpackage  rdbms_persistence_annotations 
    88 */ 
    9 stubClassLoader::load('net.stubbles.reflection.stubAnnotation', 
    10                       'net.stubbles.reflection.stubAbstractAnnotation' 
     9stubClassLoader::load('net.stubbles.reflection.annotations.stubAnnotation', 
     10                      'net.stubbles.reflection.annotations.stubAbstractAnnotation' 
    1111); 
    1212/** 
  • trunk/src/main/php/net/stubbles/reflection/annotations/stubAbstractAnnotation.php

    r65 r432  
    55 * @author      Frank Kleine <mikey@stubbles.net> 
    66 * @package     stubbles 
    7  * @subpackage  reflection 
     7 * @subpackage  reflection_annotations 
    88 */ 
     9stubClassLoader::load('net.stubbles.reflection.annotations.stubAnnotation'); 
    910/** 
    1011 * Abstract base class for annotations 
    1112 * 
    1213 * @package     stubbles 
    13  * @subpackage  reflection 
     14 * @subpackage  reflection_annotations 
    1415 */ 
    1516abstract class stubAbstractAnnotation extends stubBaseObject implements stubAnnotation 
  • trunk/src/main/php/net/stubbles/reflection/annotations/stubAnnotation.php

    r18 r432  
    55 * @author      Frank Kleine <mikey@stubbles.net> 
    66 * @package     stubbles 
    7  * @subpackage  reflection 
     7 * @subpackage  reflection_annotations 
    88 */ 
    99/** 
     
    1111 * 
    1212 * @package     stubbles 
    13  * @subpackage  reflection 
     13 * @subpackage  reflection_annotations 
    1414 */ 
    1515interface stubAnnotation 
  • trunk/src/main/php/net/stubbles/reflection/annotations/stubAnnotationCache.php

    r64 r432  
    55 * @author      Stephan Schmidt <schst@stubbles.net> 
    66 * @package     stubbles 
    7  * @subpackage  reflection 
     7 * @subpackage  reflection_annotations 
    88 */ 
    99/** 
     
    1212 * @static 
    1313 * @package     stubbles 
    14  * @subpackage  reflection 
     14 * @subpackage  reflection_annotations 
    1515 */ 
    1616class stubAnnotationCache 
  • trunk/src/main/php/net/stubbles/reflection/annotations/stubAnnotationFactory.php

    r395 r432  
    66 * @author      Stephan Schmidt <schst@stubbles.net> 
    77 * @package     stubbles 
    8  * @subpackage  reflection 
     8 * @subpackage  reflection_annotations 
    99 */ 
    10 stubClassLoader::load('net.stubbles.reflection.stubAnnotation', 
    11                       'net.stubbles.reflection.stubAnnotationCache'); 
     10stubClassLoader::load('net.stubbles.reflection.annotations.stubAnnotation', 
     11                      'net.stubbles.reflection.annotations.stubAnnotationCache' 
     12); 
    1213/** 
    1314 * Factory to create annotations. 
     
    1516 * @static 
    1617 * @package     stubbles 
    17  * @subpackage  reflection 
     18 * @subpackage  reflection_annotations 
    1819 */ 
    1920class stubAnnotationFactory 
     
    5859 
    5960        if (($annotation instanceof stubAnnotation) == false) { 
    60             throw new ReflectionException('The annotation: ' . $annotationName . ' is not an instance of reflection.stubAnnotation.'); 
     61            throw new ReflectionException('The annotation: ' . $annotationName . ' is not an instance of net.stubbles.reflection.annotations.stubAnnotation.'); 
    6162        } 
    6263        $annotationType = self::findAnnotationClass($annotationName, true); 
  • trunk/src/main/php/net/stubbles/reflection/reflection.php

    r252 r432  
    77 * @subpackage  reflection 
    88 */ 
    9 stubClassLoader::load('net.stubbles.reflection.stubAnnotation', 
    10                       'net.stubbles.reflection.stubAbstractAnnotation', 
    11                       'net.stubbles.reflection.stubAnnotationFactory', 
     9stubClassLoader::load('net.stubbles.reflection.annotations.stubAnnotation', 
     10                      'net.stubbles.reflection.annotations.stubAbstractAnnotation', 
     11                      'net.stubbles.reflection.annotations.stubAnnotationFactory', 
    1212                      'net.stubbles.reflection.stubBaseReflectionClass', 
    1313                      'net.stubbles.reflection.stubReflectionClass', 
  • trunk/src/main/php/net/stubbles/reflection/stubReflectionClass.php

    r408 r432  
    88 * @subpackage  reflection 
    99 */ 
    10 stubClassLoader::load('net.stubbles.reflection.stubAnnotationFactory', 
     10stubClassLoader::load('net.stubbles.reflection.annotations.stubAnnotationFactory', 
    1111                      'net.stubbles.reflection.stubBaseReflectionClass', 
    1212                      'net.stubbles.reflection.stubReflectionExtension', 
  • trunk/src/main/php/net/stubbles/reflection/stubReflectionFunction.php

    r253 r432  
    88 * @subpackage  reflection 
    99 */ 
    10 stubClassLoader::load('net.stubbles.reflection.stubAnnotationFactory', 
     10stubClassLoader::load('net.stubbles.reflection.annotations.stubAnnotationFactory', 
    1111                      'net.stubbles.reflection.stubReflectionParameter' 
    1212); 
  • trunk/src/main/php/net/stubbles/reflection/stubReflectionMethod.php

    r253 r432  
    88 * @subpackage  reflection 
    99 */ 
    10 stubClassLoader::load('net.stubbles.reflection.stubAnnotationFactory', 
     10stubClassLoader::load('net.stubbles.reflection.annotations.stubAnnotationFactory', 
    1111                      'net.stubbles.reflection.stubReflectionClass', 
    1212                      'net.stubbles.reflection.stubReflectionParameter' 
  • trunk/src/main/php/net/stubbles/reflection/stubReflectionObject.php

    r255 r432  
    99 */ 
    1010stubClassLoader::load('net.stubbles.reflection.stubReflectionClass', 
    11                       'net.stubbles.reflection.stubAnnotationFactory', 
     11                      'net.stubbles.reflection.annotations.stubAnnotationFactory', 
    1212                      'net.stubbles.reflection.stubBaseReflectionClass', 
    1313                      'net.stubbles.reflection.stubReflectionExtension', 
  • trunk/src/main/php/net/stubbles/reflection/stubReflectionProperty.php

    r253 r432  
    88 * @subpackage  reflection 
    99 */ 
    10 stubClassLoader::load('net.stubbles.reflection.stubAnnotationFactory', 
     10stubClassLoader::load('net.stubbles.reflection.annotations.stubAnnotationFactory', 
    1111                      'net.stubbles.reflection.stubReflectionClass' 
    1212); 
  • trunk/src/main/php/net/stubbles/xml/serializer/annotations/stubXMLAttributeAnnotation.php

    r213 r432  
    77 * @subpackage  xml_serializer 
    88 */ 
    9 stubClassLoader::load('net.stubbles.reflection.stubAnnotation', 
    10                       'net.stubbles.reflection.stubAbstractAnnotation'); 
     9stubClassLoader::load('net.stubbles.reflection.annotations.stubAnnotation', 
     10                      'net.stubbles.reflection.annotations.stubAbstractAnnotation'); 
    1111 
    1212/** 
  • trunk/src/main/php/net/stubbles/xml/serializer/annotations/stubXMLIgnoreAnnotation.php

    r213 r432  
    77 * @subpackage  xml_serializer 
    88 */ 
    9 stubClassLoader::load('net.stubbles.reflection.stubAnnotation', 
    10                       'net.stubbles.reflection.stubAbstractAnnotation'); 
     9stubClassLoader::load('net.stubbles.reflection.annotations.stubAnnotation', 
     10                      'net.stubbles.reflection.annotations.stubAbstractAnnotation'); 
    1111 
    1212/** 
  • trunk/src/main/php/net/stubbles/xml/serializer/annotations/stubXMLMatcherAnnotation.php

    r393 r432  
    77 * @subpackage  xml_serializer 
    88 */ 
    9 stubClassLoader::load('net.stubbles.reflection.stubAnnotation', 
    10                       'net.stubbles.reflection.stubAbstractAnnotation'); 
     9stubClassLoader::load('net.stubbles.reflection.annotations.stubAnnotation', 
     10                      'net.stubbles.reflection.annotations.stubAbstractAnnotation'); 
    1111 
    1212/** 
  • trunk/src/main/php/net/stubbles/xml/serializer/annotations/stubXMLPropertiesAnnotation.php

    r393 r432  
    77 * @subpackage  xml_serializer 
    88 */ 
    9 stubClassLoader::load('net.stubbles.reflection.stubAnnotation', 
    10                       'net.stubbles.reflection.stubAbstractAnnotation'); 
     9stubClassLoader::load('net.stubbles.reflection.annotations.stubAnnotation', 
     10                      'net.stubbles.reflection.annotations.stubAbstractAnnotation'); 
    1111 
    1212/** 
  • trunk/src/main/php/net/stubbles/xml/serializer/annotations/stubXMLTagAnnotation.php

    r213 r432  
    77 * @subpackage  xml_serializer 
    88 */ 
    9 stubClassLoader::load('net.stubbles.reflection.stubAnnotation', 
    10                       'net.stubbles.reflection.stubAbstractAnnotation'); 
     9stubClassLoader::load('net.stubbles.reflection.annotations.stubAnnotation', 
     10                      'net.stubbles.reflection.annotations.stubAbstractAnnotation'); 
    1111 
    1212/** 
  • trunk/src/main/php/net/stubbles/xml/xsl/XSLMethod.php

    r180 r432  
    77 * @subpackage  xml_xsl 
    88 */ 
    9 stubClassLoader::load('net.stubbles.reflection.stubAnnotation', 
    10                       'net.stubbles.reflection.stubAbstractAnnotation' 
     9stubClassLoader::load('net.stubbles.reflection.annotations.stubAnnotation', 
     10                      'net.stubbles.reflection.annotations.stubAbstractAnnotation' 
    1111); 
    1212/** 
  • trunk/src/test/php/net/stubbles/reflection/ReflectionTestSuite.php

    r41 r432  
    2121    { 
    2222        $this->TestSuite('All Reflection tests'); 
    23         $this->addTestFile(dirname(__FILE__) . '/stubAnnotationFactoryTestCase.php'); 
    24         $this->addTestFile(dirname(__FILE__) . '/stubAnnotationFactoryApplicableTestCase.php'); 
    25         $this->addTestFile(dirname(__FILE__) . '/stubAnnotationFactoryBuildTestCase.php'); 
     23        $this->addTestFile(dirname(__FILE__) . '/annotations/stubAnnotationFactoryTestCase.php'); 
     24        $this->addTestFile(dirname(__FILE__) . '/annotations/stubAnnotationFactoryApplicableTestCase.php'); 
     25        $this->addTestFile(dirname(__FILE__) . '/annotations/stubAnnotationFactoryBuildTestCase.php'); 
    2626        $this->addTestFile(dirname(__FILE__) . '/stubReflectionClassTestCase.php'); 
    2727        $this->addTestFile(dirname(__FILE__) . '/stubReflectionExtensionTestCase.php'); 
  • trunk/src/test/php/net/stubbles/reflection/annotations/stubAnnotationFactoryApplicableTestCase.php

    r98 r432  
    11<?php 
    22/** 
    3  * Test for stubAnnotationFactory::isApplicable(). 
     3 * Test for net.stubbles.reflection.annotations.stubAnnotationFactory::isApplicable(). 
    44 * 
    55 * @author      Frank Kleine <mikey@stubbles.net> 
    66 * @package     stubbles 
    7  * @subpackage  reflection_test 
     7 * @subpackage  reflection_annotations_test 
    88 */ 
    9 stubClassLoader::load('net.stubbles.reflection.stubAnnotationFactory'); 
     9stubClassLoader::load('net.stubbles.reflection.annotations.stubAnnotationFactory'); 
    1010Mock::generate('stubAnnotation'); 
    1111/** 
    12  * Test for stubAnnotationFactory::isApplicable(). 
     12 * Test for net.stubbles.reflection.annotations.stubAnnotationFactory::isApplicable(). 
    1313 * 
    1414 * @package     stubbles 
    15  * @subpackage  reflection_test 
     15 * @subpackage  reflection_annotations_test 
    1616 */ 
    1717class stubAnnotationFactoryApplicableTestCase extends UnitTestCase 
  • trunk/src/test/php/net/stubbles/reflection/annotations/stubAnnotationFactoryBuildTestCase.php

    r98 r432  
    11<?php 
    22/** 
    3  * Test for stubAnnotationFactory::build(). 
     3 * Test for net.stubbles.reflection.annotations.stubAnnotationFactory::build(). 
    44 * 
    55 * @author      Frank Kleine <mikey@stubbles.net> 
    66 * @package     stubbles 
    7  * @subpackage  reflection_test 
     7 * @subpackage  reflection_annotations_test 
    88 */ 
    9 stubClassLoader::load('net.stubbles.reflection.stubAnnotationFactory'); 
     9stubClassLoader::load('net.stubbles.reflection.annotations.stubAnnotationFactory'); 
    1010Mock::generate('stubAnnotation'); 
    1111class stubMethodAnnotation implements stubAnnotation 
     
    4444} 
    4545/** 
    46  * Test for stubAnnotationFactory::build(). 
     46 * Test for net.stubbles.reflection.annotations.stubAnnotationFactory::build(). 
    4747 * 
    4848 * @package     stubbles 
    49  * @subpackage  reflection_test 
     49 * @subpackage  reflection_annotations_test 
    5050 */ 
    5151class stubAnnotationFactoryBuildTestCase extends UnitTestCase 
  • trunk/src/test/php/net/stubbles/reflection/annotations/stubAnnotationFactoryTestCase.php

    r223 r432  
    11<?php 
    22/** 
    3  * Test for stubAnnotationFactory. 
     3 * Test for net.stubbles.reflection.annotations.stubAnnotationFactory. 
    44 * 
    55 * @author      Frank Kleine <mikey@stubbles.net> 
    66 * @author      Stephan Schmidt <schst@stubbles.net> 
    77 * @package     stubbles 
    8  * @subpackage  reflection_test 
     8 * @subpackage  reflection_annotations_test 
    99 */ 
    10 stubClassLoader::load('net.stubbles.reflection.stubAnnotationFactory', 
    11                       'net.stubbles.reflection.stubAnnotation', 
    12                       'net.stubbles.reflection.stubAbstractAnnotation', 
     10stubClassLoader::load('net.stubbles.reflection.annotations.stubAnnotationFactory', 
     11                      'net.stubbles.reflection.annotations.stubAnnotation', 
     12                      'net.stubbles.reflection.annotations.stubAbstractAnnotation', 
    1313                      'net.stubbles.reflection.stubReflectionClass' 
    1414); 
    15  
    1615 
    1716/** 
    1817 * Test Annotation 
    1918 * 
    20  * @author      Stephan Schmidt <schst@stubbles.net> 
    2119 * @package     stubbles 
    22  * @subpackage  reflection_test 
     20 * @subpackage  reflection_annotations_test 
    2321 */ 
    24 class MyAnnotation extends stubAbstractAnnotation implements stubAnnotation { 
    25      
     22class MyAnnotation extends stubAbstractAnnotation implements stubAnnotation 
     23
    2624    public $foo; 
    2725    public $argh; 
     
    3331     * @return  int 
    3432     */ 
    35     public function getAnnotationTarget() { 
    36         return stubAnnotation::TARGET_ALL; 
    37     }     
     33    public function getAnnotationTarget() { return stubAnnotation::TARGET_ALL; }     
    3834} 
    3935 
     
    4238 * 
    4339 */ 
    44 interface CastedAnnotation { 
     40interface CastedAnnotation { } 
     41 
     42/** 
     43 * Test Annotation 
     44 * 
     45 * @author      Stephan Schmidt <schst@stubbles.net> 
     46 * @package     stubbles 
     47 * @subpackage  reflection_test 
     48 */ 
     49class AnotherAnnotation extends stubAbstractAnnotation implements stubAnnotation, CastedAnnotation 
     50
     51    public $value; 
     52    public function getAnnotationTarget() { return stubAnnotation::TARGET_ALL; }     
    4553} 
    4654 
     
    5260 * @subpackage  reflection_test 
    5361 */ 
    54 class AnotherAnnotation extends stubAbstractAnnotation implements stubAnnotation, CastedAnnotation { 
    55      
    56     public $value; 
    57      
    58     public function getAnnotationTarget() { 
    59         return stubAnnotation::TARGET_ALL; 
    60     }     
    61 
    62  
    63 /** 
    64  * Test Annotation 
    65  * 
    66  * @author      Stephan Schmidt <schst@stubbles.net> 
    67  * @package     stubbles 
    68  * @subpackage  reflection_test 
    69  */ 
    70 class EmptyAnnotation extends stubAbstractAnnotation implements stubAnnotation { 
    71     public function getAnnotationTarget() { 
    72         return stubAnnotation::TARGET_CLASS; 
    73     }     
     62class EmptyAnnotation extends stubAbstractAnnotation implements stubAnnotation 
     63
     64    public function getAnnotationTarget() { return stubAnnotation::TARGET_CLASS; }     
    7465} 
    7566 
     
    8879 
    8980/** 
    90  * Test for stubAnnotationFactory. 
     81 * Test for net.stubbles.reflection.annotations.stubAnnotationFactory. 
    9182 * 
    9283 * @package     stubbles