Changeset 1209
- Timestamp:
- 01/11/08 01:44:43 (9 months ago)
- Files:
-
- trunk/src/main/php/net/stubbles/auth/storage/stubAuthAbstractStorage.php (modified) (1 diff)
- trunk/src/main/php/net/stubbles/auth/storage/stubAuthSessionStorage.php (modified) (1 diff)
- trunk/src/main/php/net/stubbles/auth/strategy/stubAuthFailOverStrategy.php (modified) (1 diff)
- trunk/src/main/php/net/stubbles/auth/strategy/stubAuthOrStrategy.php (modified) (1 diff)
- trunk/src/main/php/net/stubbles/auth/stubAuth.php (modified) (1 diff)
- trunk/src/main/php/net/stubbles/events/events.php (modified) (1 diff)
- trunk/src/main/php/net/stubbles/events/stubCallbackListener.php (modified) (1 diff)
- trunk/src/main/php/net/stubbles/events/stubEventDispatcher.php (modified) (1 diff)
- trunk/src/main/php/net/stubbles/events/stubEventsXJConfInitializer.php (modified) (1 diff)
- trunk/src/main/php/net/stubbles/events/stubLazyEventListener.php (modified) (1 diff)
- trunk/src/main/php/net/stubbles/events/stubNonCancelableEvent.php (modified) (1 diff)
- trunk/src/main/php/net/stubbles/lang/errorhandler/stubAbstractExceptionHandler.php (modified) (2 diffs)
- trunk/src/main/php/net/stubbles/lang/errorhandler/stubCompositeErrorHandler.php (modified) (1 diff)
- trunk/src/main/php/net/stubbles/lang/errorhandler/stubDefaultErrorHandler.php (modified) (1 diff)
- trunk/src/main/php/net/stubbles/lang/errorhandler/stubDisplayExceptionHandler.php (modified) (1 diff)
- trunk/src/main/php/net/stubbles/lang/errorhandler/stubIllegalArgumentErrorHandler.php (modified) (1 diff)
- trunk/src/main/php/net/stubbles/lang/errorhandler/stubLogErrorHandler.php (modified) (1 diff)
- trunk/src/main/php/net/stubbles/lang/errorhandler/stubProdModeExceptionHandler.php (modified) (1 diff)
- trunk/src/main/php/net/stubbles/lang/exceptions/stubChainedException.php (modified) (1 diff)
- trunk/src/main/php/net/stubbles/lang/exceptions/stubException.php (modified) (3 diffs)
- trunk/src/main/php/net/stubbles/lang/exceptions/stubFileNotFoundException.php (modified) (2 diffs)
- trunk/src/main/php/net/stubbles/lang/exceptions/stubMethodNotSupportedException.php (modified) (1 diff)
- trunk/src/main/php/net/stubbles/lang/exceptions/stubRuntimeException.php (modified) (3 diffs)
- trunk/src/main/php/net/stubbles/lang/serialize/stubSerializedObject.php (modified) (3 diffs)
- trunk/src/main/php/net/stubbles/lang/stubBaseObject.php (modified) (4 diffs)
- trunk/src/main/php/net/stubbles/lang/stubEnum.php (modified) (1 diff)
- trunk/src/main/php/net/stubbles/lang/stubMode.php (modified) (5 diffs)
- trunk/src/main/php/net/stubbles/lang/stubObject.php (modified) (1 diff)
- trunk/src/main/php/net/stubbles/reflection/stubReflectionClass.php (modified) (1 diff)
- trunk/src/main/php/net/stubbles/reflection/stubReflectionPackage.php (modified) (8 diffs)
- trunk/src/main/php/net/stubbles/stubClassLoader.php (modified) (8 diffs)
- trunk/src/main/php/net/stubbles/util/xjconf/stubXJConfLoader.php (modified) (1 diff)
- trunk/src/main/resources/xjconf/events.xml (modified) (3 diffs)
- trunk/src/test/php/net/stubbles/auth/storage/stubAuthSessionStorageTestCase.php (modified) (2 diffs)
- trunk/src/test/php/net/stubbles/auth/strategy/stubAuthFailOverStrategyTestCase.php (modified) (2 diffs)
- trunk/src/test/php/net/stubbles/auth/strategy/stubAuthOrStrategyTestCase.php (modified) (2 diffs)
- trunk/src/test/php/net/stubbles/auth/strategy/stubAuthStrategyBaseTestCase.php (modified) (2 diffs)
- trunk/src/test/php/net/stubbles/auth/stubAuthTestCase.php (modified) (2 diffs)
- trunk/src/test/php/net/stubbles/events/stubCallbackListenerTestCase.php (modified) (2 diffs)
- trunk/src/test/php/net/stubbles/events/stubEventDispatcherTestCase.php (modified) (2 diffs)
- trunk/src/test/php/net/stubbles/events/stubEventTestCase.php (modified) (2 diffs)
- trunk/src/test/php/net/stubbles/events/stubLazyEventListenerTestCase.php (modified) (3 diffs)
- trunk/src/test/php/net/stubbles/events/stubNonCancelableEventTestCase.php (modified) (2 diffs)
- trunk/src/test/php/net/stubbles/lang/errorhandler/stubAbstractExceptionHandlerTestCase.php (modified) (4 diffs)
- trunk/src/test/php/net/stubbles/lang/errorhandler/stubCompositeErrorHandlerTestCase.php (modified) (1 diff)
- trunk/src/test/php/net/stubbles/lang/errorhandler/stubIllegalArgumentErrorHandlerTestCase.php (modified) (1 diff)
- trunk/src/test/php/net/stubbles/lang/errorhandler/stubLogErrorHandlerTestCase.php (modified) (1 diff)
- trunk/src/test/php/net/stubbles/lang/exceptions/stubChainedExceptionTestCase.php (modified) (4 diffs)
- trunk/src/test/php/net/stubbles/lang/exceptions/stubExceptionTestCase.php (modified) (3 diffs)
- trunk/src/test/php/net/stubbles/lang/serialize/stubSerializableObjectTestCase.php (modified) (7 diffs)
- trunk/src/test/php/net/stubbles/lang/serialize/stubSerializedObjectTestCase.php (modified) (6 diffs)
- trunk/src/test/php/net/stubbles/lang/stubBaseObjectTestCase.php (modified) (4 diffs)
- trunk/src/test/php/net/stubbles/lang/stubEnumTestCase.php (modified) (5 diffs)
- trunk/src/test/php/net/stubbles/lang/stubModeTestCase.php (modified) (2 diffs)
- trunk/src/test/php/net/stubbles/reflection/stubReflectionPackageTestCase.php (modified) (10 diffs)
- trunk/src/test/php/net/stubbles/stubClassLoaderTestCase.php (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/src/main/php/net/stubbles/auth/storage/stubAuthAbstractStorage.php
r756 r1209 7 7 * @subpackage auth_storage 8 8 */ 9 stubClassLoader::load('net .stubbles.auth.storage.stubAuthStorage');9 stubClassLoader::load('net::stubbles::auth::storage::stubAuthStorage'); 10 10 /** 11 11 * Basic implementation for the authentication result. trunk/src/main/php/net/stubbles/auth/storage/stubAuthSessionStorage.php
r756 r1209 7 7 * @subpackage auth_storage 8 8 */ 9 stubClassLoader::load('net .stubbles.auth.storage.stubAuthAbstractStorage',10 'net .stubbles.ipo.session.stubSession'9 stubClassLoader::load('net::stubbles::auth::storage::stubAuthAbstractStorage', 10 'net::stubbles::ipo::session::stubSession' 11 11 ); 12 12 /** trunk/src/main/php/net/stubbles/auth/strategy/stubAuthFailOverStrategy.php
r756 r1209 7 7 * @subpackage auth_strategy 8 8 */ 9 stubClassLoader::load('net .stubbles.auth.strategy.stubAuthStrategy');9 stubClassLoader::load('net::stubbles::auth::strategy::stubAuthStrategy'); 10 10 /** 11 11 * Authentication strategy that uses the first authenticator and the other only if the first fails. trunk/src/main/php/net/stubbles/auth/strategy/stubAuthOrStrategy.php
r756 r1209 7 7 * @subpackage auth_strategy 8 8 */ 9 stubClassLoader::load('net .stubbles.auth.strategy.stubAuthStrategy');9 stubClassLoader::load('net::stubbles::auth::strategy::stubAuthStrategy'); 10 10 /** 11 11 * Authentication strategy that tries all authenticators until one was successful or all have been used. trunk/src/main/php/net/stubbles/auth/stubAuth.php
r756 r1209 7 7 * @subpackage auth 8 8 */ 9 stubClassLoader::load('net .stubbles.auth.authenticators.stubAuthenticator',10 'net .stubbles.auth.storage.stubAuthStorage',11 'net .stubbles.auth.strategy.stubAuthStrategy',12 'net .stubbles.auth.stubAuthException',13 'net .stubbles.auth.stubAuthResult'9 stubClassLoader::load('net::stubbles::auth::authenticators::stubAuthenticator', 10 'net::stubbles::auth::storage::stubAuthStorage', 11 'net::stubbles::auth::strategy::stubAuthStrategy', 12 'net::stubbles::auth::stubAuthException', 13 'net::stubbles::auth::stubAuthResult' 14 14 ); 15 15 /** trunk/src/main/php/net/stubbles/events/events.php
r97 r1209 7 7 * @subpackage events 8 8 */ 9 stubClassLoader::load('net .stubbles.events.stubEvent',10 'net .stubbles.events.stubEventListener',11 'net .stubbles.events.stubEventDispatcher'9 stubClassLoader::load('net::stubbles::events::stubEvent', 10 'net::stubbles::events::stubEventListener', 11 'net::stubbles::events::stubEventDispatcher' 12 12 ); 13 13 ?> trunk/src/main/php/net/stubbles/events/stubCallbackListener.php
r1127 r1209 7 7 * @subpackage events 8 8 */ 9 stubClassLoader::load('net .stubbles.events.stubCallbackException',10 'net .stubbles.events.stubEvent',11 'net .stubbles.events.stubEventListener',12 'net .stubbles.lang.exceptions.stubIllegalArgumentException'9 stubClassLoader::load('net::stubbles::events::stubCallbackException', 10 'net::stubbles::events::stubEvent', 11 'net::stubbles::events::stubEventListener', 12 'net::stubbles::lang::exceptions::stubIllegalArgumentException' 13 13 ); 14 14 /** trunk/src/main/php/net/stubbles/events/stubEventDispatcher.php
r1035 r1209 8 8 * @subpackage events 9 9 */ 10 stubClassLoader::load('net .stubbles.events.stubEvent',11 'net .stubbles.events.stubEventListener'10 stubClassLoader::load('net::stubbles::events::stubEvent', 11 'net::stubbles::events::stubEventListener' 12 12 ); 13 13 /** trunk/src/main/php/net/stubbles/events/stubEventsXJConfInitializer.php
r1174 r1209 7 7 * @subpackage events 8 8 */ 9 stubClassLoader::load('net .stubbles.events.events',10 'net .stubbles.events.stubEventsInitializer',11 'net .stubbles.ipo.interceptors.stubPreInterceptor',12 'net .stubbles.lang.exceptions.stubIllegalArgumentException',13 'net .stubbles.util.xjconf.xjconf'9 stubClassLoader::load('net::stubbles::events::events', 10 'net::stubbles::events::stubEventsInitializer', 11 'net::stubbles::ipo::interceptors::stubPreInterceptor', 12 'net::stubbles::lang::exceptions::stubIllegalArgumentException', 13 'net::stubbles::util::xjconf::xjconf' 14 14 ); 15 15 /** trunk/src/main/php/net/stubbles/events/stubLazyEventListener.php
r1127 r1209 7 7 * @subpackage events 8 8 */ 9 stubClassLoader::load('net .stubbles.events.stubEventListener');9 stubClassLoader::load('net::stubbles::events::stubEventListener'); 10 10 /** 11 11 * Class for lazy loading of concrete event listeners. trunk/src/main/php/net/stubbles/events/stubNonCancelableEvent.php
r345 r1209 7 7 * @subpackage events 8 8 */ 9 stubClassLoader::load('net .stubbles.events.stubEvent');9 stubClassLoader::load('net::stubbles::events::stubEvent'); 10 10 /** 11 11 * Event that can not be cancelled. trunk/src/main/php/net/stubbles/lang/errorhandler/stubAbstractExceptionHandler.php
r1093 r1209 7 7 * @subpackage lang_errorhandler 8 8 */ 9 stubClassLoader::load('net .stubbles.ipo.response.stubBaseResponse',10 'net .stubbles.lang.errorhandler.stubExceptionHandler',11 'net .stubbles.util.log.log'9 stubClassLoader::load('net::stubbles::ipo::response::stubBaseResponse', 10 'net::stubbles::lang::errorhandler::stubExceptionHandler', 11 'net::stubbles::util::log::log' 12 12 ); 13 13 /** … … 102 102 protected function log(Exception $exception) 103 103 { 104 stubClassLoader::load('net.stubbles.util.log.log');105 104 $logData = stubLogDataFactory::create($this->logTarget, $this->logLevel); 106 105 $logData->addData(($exception instanceof stubThrowable) ? ($exception->getClassName()) : (get_class($exception))); trunk/src/main/php/net/stubbles/lang/errorhandler/stubCompositeErrorHandler.php
r1102 r1209 7 7 * @subpackage lang_errorhandler 8 8 */ 9 stubClassLoader::load('net .stubbles.lang.errorhandler.stubErrorHandler');9 stubClassLoader::load('net::stubbles::lang::errorhandler::stubErrorHandler'); 10 10 /** 11 11 * Container for a collection of PHP error handlers. trunk/src/main/php/net/stubbles/lang/errorhandler/stubDefaultErrorHandler.php
r1095 r1209 7 7 * @subpackage lang_errorhandler 8 8 */ 9 stubClassLoader::load('net .stubbles.lang.errorhandler.stubCompositeErrorHandler',10 'net .stubbles.lang.errorhandler.stubIllegalArgumentErrorHandler',11 'net .stubbles.lang.errorhandler.stubLogErrorHandler'9 stubClassLoader::load('net::stubbles::lang::errorhandler::stubCompositeErrorHandler', 10 'net::stubbles::lang::errorhandler::stubIllegalArgumentErrorHandler', 11 'net::stubbles::lang::errorhandler::stubLogErrorHandler' 12 12 ); 13 13 /** trunk/src/main/php/net/stubbles/lang/errorhandler/stubDisplayExceptionHandler.php
r1092 r1209 7 7 * @subpackage lang_errorhandler 8 8 */ 9 stubClassLoader::load('net .stubbles.lang.errorhandler.stubAbstractExceptionHandler');9 stubClassLoader::load('net::stubbles::lang::errorhandler::stubAbstractExceptionHandler'); 10 10 /** 11 11 * Exception handler that displays the exception message nicely formated in the response. trunk/src/main/php/net/stubbles/lang/errorhandler/stubIllegalArgumentErrorHandler.php
r1092 r1209 7 7 * @subpackage lang_errorhandler 8 8 */ 9 stubClassLoader::load('net .stubbles.lang.errorhandler.stubErrorHandler',10 'net .stubbles.lang.exceptions.stubIllegalArgumentException'9 stubClassLoader::load('net::stubbles::lang::errorhandler::stubErrorHandler', 10 'net::stubbles::lang::exceptions::stubIllegalArgumentException' 11 11 ); 12 12 /** trunk/src/main/php/net/stubbles/lang/errorhandler/stubLogErrorHandler.php
r1118 r1209 7 7 * @subpackage lang_errorhandler 8 8 */ 9 stubClassLoader::load('net .stubbles.lang.errorhandler.stubErrorHandler');9 stubClassLoader::load('net::stubbles::lang::errorhandler::stubErrorHandler'); 10 10 /** 11 11 * Error handler that logs all errors. trunk/src/main/php/net/stubbles/lang/errorhandler/stubProdModeExceptionHandler.php
r1092 r1209 7 7 * @subpackage lang_errorhandler 8 8 */ 9 stubClassLoader::load('net .stubbles.lang.errorhandler.stubAbstractExceptionHandler');9 stubClassLoader::load('net::stubbles::lang::errorhandler::stubAbstractExceptionHandler'); 10 10 /** 11 11 * Exception handler for production mode: triggers a 500 Internal Server Error response. trunk/src/main/php/net/stubbles/lang/exceptions/stubChainedException.php
r777 r1209 51 51 * [fully-qualified-class-name] ' {' [members-and-value-list] '}' 52 52 * <code> 53 * example .MyException {53 * example::MyException { 54 54 * message(string): This is an exception. 55 55 * file(string): foo.php trunk/src/main/php/net/stubbles/lang/exceptions/stubException.php
r887 r1209 23 23 public function getClass() 24 24 { 25 stubClassLoader::load('net .stubbles.reflection.stubReflectionObject');25 stubClassLoader::load('net::stubbles::reflection::stubReflectionObject'); 26 26 $refObject = new stubReflectionObject($this); 27 27 return $refObject; … … 36 36 public function getPackage() 37 37 { 38 stubClassLoader::load('net .stubbles.reflection.stubReflectionPackage');38 stubClassLoader::load('net::stubbles::reflection::stubReflectionPackage'); 39 39 $refPackage = new stubReflectionPackage(stubClassLoader::getPackageName($this->getClassName())); 40 40 return $refPackage; … … 96 96 * [fully-qualified-class-name] ' {' [members-and-value-list] '}' 97 97 * <code> 98 * example .MyException {98 * example::MyException { 99 99 * message(string): This is an exception. 100 100 * file(string): foo.php trunk/src/main/php/net/stubbles/lang/exceptions/stubFileNotFoundException.php
r1127 r1209 1 1 <?php 2 2 /** 3 * Exception to be thrown in case a file could not be found 3 * Exception to be thrown in case a file could not be found. 4 4 * 5 5 * @author Stephan Schmidt <schst@stubbles.net> … … 7 7 * @subpackage lang_exceptions 8 8 */ 9 stubClassLoader::load('net .stubbles.lang.exceptions.stubIOException');9 stubClassLoader::load('net::stubbles::lang::exceptions::stubIOException'); 10 10 /** 11 * Exception to be thrown in case a n IO error occurred.11 * Exception to be thrown in case a file could not be found. 12 12 * 13 13 * @author Stephan Schmidt <schst@stubbles.net> trunk/src/main/php/net/stubbles/lang/exceptions/stubMethodNotSupportedException.php
r958 r1209 8 8 * @subpackage lang_exceptions 9 9 */ 10 stubClassLoader::load('net .stubbles.lang.exceptions.stubRuntimeException');10 stubClassLoader::load('net::stubbles::lang::exceptions::stubRuntimeException'); 11 11 /** 12 12 * Exception to be thrown in case a method is called which is not supported by trunk/src/main/php/net/stubbles/lang/exceptions/stubRuntimeException.php
r887 r1209 28 28 public function getClass() 29 29 { 30 stubClassLoader::load('net .stubbles.reflection.stubReflectionObject');30 stubClassLoader::load('net::stubbles::reflection::stubReflectionObject'); 31 31 $refObject = new stubReflectionObject($this); 32 32 return $refObject; … … 41 41 public function getPackage() 42 42 { 43 stubClassLoader::load('net .stubbles.reflection.stubReflectionPackage');43 stubClassLoader::load('net::stubbles::reflection::stubReflectionPackage'); 44 44 $refPackage = new stubReflectionPackage(stubClassLoader::getPackageName($this->getClassName())); 45 45 return $refPackage; … … 101 101 * [fully-qualified-class-name] ' {' [members-and-value-list] '}' 102 102 * <code> 103 * net .stubbles.lang.exceptions.stubRuntimeException {103 * net::stubbles::lang::exceptions::stubRuntimeException { 104 104 * message(string): This is a runtime exception. 105 105 * file(string): foo.php trunk/src/main/php/net/stubbles/lang/serialize/stubSerializedObject.php
r777 r1209 121 121 public function getClass() 122 122 { 123 stubClassLoader::load('net .stubbles.reflection.stubReflectionObject');123 stubClassLoader::load('net::stubbles::reflection::stubReflectionObject'); 124 124 $refObject = new stubReflectionObject($this); 125 125 return $refObject; … … 134 134 public function getPackage() 135 135 { 136 stubClassLoader::load('net .stubbles.reflection.stubReflectionPackage');136 stubClassLoader::load('net::stubbles::reflection::stubReflectionPackage'); 137 137 $refPackage = new stubReflectionPackage(stubClassLoader::getPackageName($this->getClassName())); 138 138 return $refPackage; … … 206 206 * [fully-qualified-class-name] ' {' [members-and-value-list] '}' 207 207 * <code> 208 * net .stubbles.lang.serialize.stubSerializedObject {209 * class(string): net .stubbles.stubExample210 * data(string): [serialized representation of net .stubbles.stubExample]208 * net::stubbles::lang::serialize::stubSerializedObject { 209 * class(string): net:.stubbles::stubExample 210 * data(string): [serialized representation of net::stubbles::stubExample] 211 211 * } 212 212 * </code> trunk/src/main/php/net/stubbles/lang/stubBaseObject.php
r1127 r1209 25 25 public function getClass() 26 26 { 27 stubClassLoader::load('net .stubbles.reflection.stubReflectionObject');27 stubClassLoader::load('net::stubbles::reflection::stubReflectionObject'); 28 28 $refObject = new stubReflectionObject($this); 29 29 return $refObject; … … 38 38 public function getPackage() 39 39 { 40 stubClassLoader::load('net .stubbles.reflection.stubReflectionPackage');40 stubClassLoader::load('net::stubbles::reflection::stubReflectionPackage'); 41 41 $refPackage = new stubReflectionPackage(stubClassLoader::getPackageName($this->getClassName())); 42 42 return $refPackage; … … 99 99 * [fully-qualified-class-name] ' {' [members-and-value-list] '}' 100 100 * <code> 101 * example .MyClass {101 * example::MyClass { 102 102 * foo(string): hello 103 * bar(example .AnotherClass): example.AnotherClass {103 * bar(example::AnotherClass): example::AnotherClass { 104 104 * baz(int): 5 105 105 * } … … 147 147 * [fully-qualified-class-name] ' {' [members-and-value-list] '}' 148 148 * <code> 149 * example .MyClass {149 * example::MyClass { 150 150 * foo(string): hello 151 * bar(example .AnotherClass): example.AnotherClass {151 * bar(example::AnotherClass): example::AnotherClass { 152 152 * baz(int): 5 153 153 * } trunk/src/main/php/net/stubbles/lang/stubEnum.php
r1127 r1209 7 7 * @subpackage lang 8 8 */ 9 stubClassLoader::load('net .stubbles.lang.exceptions.stubIllegalArgumentException');9 stubClassLoader::load('net::stubbles::lang::exceptions::stubIllegalArgumentException'); 10 10 /** 11 11 * Base class for enums. trunk/src/main/php/net/stubbles/lang/stubMode.php
r1139 r1209 7 7 * @subpackage lang 8 8 */ 9 stubClassLoader::load('net .stubbles.lang.stubEnum',10 'net .stubbles.lang.exceptions.stubIllegalArgumentException'9 stubClassLoader::load('net::stubbles::lang::stubEnum', 10 'net::stubbles::lang::exceptions::stubIllegalArgumentException' 11 11 ); 12 12 /** … … 114 114 // production mode 115 115 self::$PROD = new self('PROD', 0); 116 self::$PROD->exceptionHandler = array('class' => 'net .stubbles.lang.errorhandler.stubProdModeExceptionHandler',117 'method' => 'handleException', 118 'type' => self::HANDLER_INSTANCE 119 ); 120 self::$PROD->errorHandler = array('class' => 'net .stubbles.lang.errorhandler.stubDefaultErrorHandler',116 self::$PROD->exceptionHandler = array('class' => 'net::stubbles::lang::errorhandler::stubProdModeExceptionHandler', 117 'method' => 'handleException', 118 'type' => self::HANDLER_INSTANCE 119 ); 120 self::$PROD->errorHandler = array('class' => 'net::stubbles::lang::errorhandler::stubDefaultErrorHandler', 121 121 'method' => 'handle', 122 122 'type' => self::HANDLER_INSTANCE … … 125 125 // test mode 126 126 self::$TEST = new self('TEST', 1); 127 self::$TEST->exceptionHandler = array('class' => 'net .stubbles.lang.errorhandler.stubDisplayExceptionHandler',128 'method' => 'handleException', 129 'type' => self::HANDLER_INSTANCE 130 ); 131 self::$TEST->errorHandler = array('class' => 'net .stubbles.lang.errorhandler.stubDefaultErrorHandler',127 self::$TEST->exceptionHandler = array('class' => 'net::stubbles::lang::errorhandler::stubDisplayExceptionHandler', 128 'method' => 'handleException', 129 'type' => self::HANDLER_INSTANCE 130 ); 131 self::$TEST->errorHandler = array('class' => 'net::stubbles::lang::errorhandler::stubDefaultErrorHandler', 132 132 'method' => 'handle', 133 133 'type' => self::HANDLER_INSTANCE … … 136 136 // stage mode 137 137 self::$STAGE = new self('STAGE', 2); 138 self::$STAGE->exceptionHandler = array('class' => 'net .stubbles.lang.errorhandler.stubDisplayExceptionHandler',138 self::$STAGE->exceptionHandler = array('class' => 'net::stubbles::lang::errorhandler::stubDisplayExceptionHandler', 139 139 'method' => 'handleException', 140 140 'type' => self::HANDLER_INSTANCE … … 144 144 // development mode 145 145 self::$DEV = new self('DEV', 3); 146 self::$DEV->exceptionHandler = array('class' => 'net .stubbles.lang.errorhandler.stubDisplayExceptionHandler',146 self::$DEV->exceptionHandler = array('class' => 'net::stubbles::lang::errorhandler::stubDisplayExceptionHandler', 147 147 'method' => 'handleException', 148 148 'type' => self::HANDLER_INSTANCE trunk/src/main/php/net/stubbles/lang/stubObject.php
r777 r1209 69 69 * example.MyClass { 70 70 * foo(string): hello 71 * bar(example .AnotherClass): example.AnotherClass {71 * bar(example::AnotherClass): example::AnotherClass { 72 72 * baz(int): 5 73 73 * } trunk/src/main/php/net/stubbles/reflection/stubReflectionClass.php
r1127 r1209 37 37 public function __construct($className) 38 38 { 39 if (strstr($className, ' .') !== false) {39 if (strstr($className, '::') !== false || strstr($className, '.') !== false) { 40 40 $nqClassName = stubClassLoader::getNonQualifiedClassName($className); 41 41 if (class_exists($nqClassName, false) === false) { trunk/src/main/php/net/stubbles/reflection/stubReflectionPackage.php
r733 r1209 7 7 * @subpackage reflection 8 8 */ 9 stubClassLoader::load('net .stubbles.reflection.stubBaseReflectionClass');9 stubClassLoader::load('net::stubbles::reflection::stubBaseReflectionClass'); 10 10 /** 11 11 * Extended Reflection class for packages. … … 17 17 { 18 18 /** 19 * the package separator character 20 */ 21 const SEPARATOR = '::'; 22 /** 19 23 * name of the reflected package 20 24 * … … 63 67 public function __toString() 64 68 { 65 return 'net .stubbles.reflection.stubReflectionPackage[' . $this->packageName . "] {\n}\n";69 return 'net::stubbles::reflection::stubReflectionPackage[' . $this->packageName . "] {\n}\n"; 66 70 } 67 71 … … 85 89 { 86 90 $classNames = stubClassLoader::getClassNames($this->packageName, false); 87 return in_array($this->packageName . '.'. $nqClassName, $classNames);91 return in_array($this->packageName . self::SEPARATOR . $nqClassName, $classNames); 88 92 } 89 93 … … 97 101 public function getClass($nqClassName) 98 102 { 99 $stubRefClass = new stubReflectionClass($this->packageName . '.'. $nqClassName);103 $stubRefClass = new stubReflectionClass($this->packageName . self::SEPARATOR . $nqClassName); 100 104 return $stubRefClass; 101 105 } … … 148 152 public function getPackage($name) 149 153 { 150 return new self($this->packageName . '.'. $name);154 return new self($this->packageName . self::SEPARATOR . $name); 151 155 } 152 156 … … 167 171 } 168 172 169 $shortName = str_replace($this->packageName . '.', '', $packageName);170 if (strstr($shortName, '.') !== false && false === $recursive) {173 $shortName = str_replace($this->packageName . self::SEPARATOR, '', $packageName); 174 if (strstr($shortName, self::SEPARATOR) !== false && false === $recursive) { 171 175 continue; 172 176 } … … 191 195 $refPackages = array(); 192 196 foreach ($packages as $package) { 193 $refPackages[] = new self($this->packageName . '.'. $package);197 $refPackages[] = new self($this->packageName . self::SEPARATOR . $package); 194 198 } 195 199 trunk/src/main/php/net/stubbles/stubClassLoader.php
r887 r1209 99 99 public function __toString() 100 100 { 101 $string = "net .stubbles.stubClassNotFoundException {\n";101 $string = "net::stubbles::stubClassNotFoundException {\n"; 102 102 $string .= ' message(string): ' . $this->getMessage() . "\n"; 103 103 $string .= ' classname(string): ' . $this->fqClassName . "\n"; … … 126 126 * @var array<string,string> 127 127 */ 128 private static $classNames = array('net .stubbles.stubClassLoader' => 'stubClassLoader',129 'net .stubbles.stubClassNotFoundException' => 'stubClassNotFoundException',130 'net .stubbles.stubForeignClassLoader' => 'stubForeignClassLoader'128 private static $classNames = array('net::stubbles::stubClassLoader' => 'stubClassLoader', 129 'net::stubbles::stubClassNotFoundException' => 'stubClassNotFoundException', 130 'net::stubbles::stubForeignClassLoader' => 'stubForeignClassLoader' 131 131 ); 132 132 /** … … 207 207 } 208 208 if (null === $uri) { 209 $uri = self::$sourcePath . str_replace(' .', DIRECTORY_SEPARATOR, $fqClassName) . '.php';209 $uri = self::$sourcePath . str_replace('::', DIRECTORY_SEPARATOR, str_replace('.', DIRECTORY_SEPARATOR, $fqClassName)) . '.php'; 210 210 } 211 211 … … 233 233 } 234 234 235 $dirName = self::$sourcePath . str_replace('.', DIRECTORY_SEPARATOR, $packageName);235 $dirName = self::$sourcePath . str_replace('.', DIRECTORY_SEPARATOR, str_replace('::', DIRECTORY_SEPARATOR, $packageName)); 236 236 if (file_exists($dirName) == false) { 237 237 return array(); … … 250 250 } 251 251 252 $classes[] = str_replace(DIRECTORY_SEPARATOR, ' .', str_replace('.php', '', str_replace(self::$sourcePath, '', $file->getPathname())));252 $classes[] = str_replace(DIRECTORY_SEPARATOR, '::', str_replace('.php', '', str_replace(self::$sourcePath, '', $file->getPathname()))); 253 253 } 254 254 … … 281 281 public static function getNonQualifiedClassName($fqClassName) 282 282 { 283 $classNameParts = explode('.', $fqClassName); 283 if (strstr($fqClassName, '.') === false) { 284 $classNameParts = explode('::', $fqClassName); 285 } else { 286 $classNameParts = explode('.', $fqClassName); 287 } 288 284 289 return $classNameParts[count($classNameParts) - 1]; 285 290 } … … 308 313 public static function getPackageName($fqClassName) 309 314 { 310 $classNameParts = explode(' .', $fqClassName);315 $classNameParts = explode('::', $fqClassName); 311 316 unset($classNameParts[count($classNameParts) - 1]); 312 return join(' .', $classNameParts);317 return join('::', $classNameParts); 313 318 } 314 319 … … 344 349 * every other class that should extend it 345 350 */ 346 stubClassLoader::load('net .stubbles.lang.stubObject',347 'net .stubbles.lang.stubBaseObject',348 'net .stubbles.lang.exceptions.stubThrowable',349 'net .stubbles.lang.exceptions.stubException',350 'net .stubbles.lang.exceptions.stubRuntimeException',351 'net .stubbles.lang.serialize.stubSerializable',352 'net .stubbles.lang.serialize.stubSerializableObject',353 'net .stubbles.lang.serialize.stubSerializedObject'351 stubClassLoader::load('net::stubbles::lang::stubObject', 352 'net::stubbles::lang::stubBaseObject', 353 'net::stubbles::lang::exceptions::stubThrowable', 354 'net::stubbles::lang::exceptions::stubException', 355 'net::stubbles::lang::exceptions::stubRuntimeException', 356 'net::stubbles::lang::serialize::stubSerializable', 357 'net::stubbles::lang::serialize::stubSerializableObject', 358 'net::stubbles::lang::serialize::stubSerializedObject' 354 359 ); 355 360 ?> trunk/src/main/php/net/stubbles/util/xjconf/stubXJConfLoader.php
r580
