Added the Interfaces package.
authorGunnar Wrobel <p@rdus.de>
Mon, 30 Aug 2010 07:12:59 +0000 (09:12 +0200)
committerGunnar Wrobel <p@rdus.de>
Mon, 30 Aug 2010 07:12:59 +0000 (09:12 +0200)
commit549a1a57841717f032d1d95e86d10679297356e1
treef29c41bc8029e7bcc975d42f2cb757951760bb9d
parent3982d3163400fe4b8d96c115b84b33ecf2bd363d
Added the Interfaces package.

Rationale:

When looking at the Kolab_Session package I realized that
"Horde_Auth::getAuth()" calls have been converted to
"$GLOBALS['registry']->getAuth()". While this may be fine on the
application level I don't think it is acceptable on the level of a
framework package.

"$GLOBALS['registry']->getAuth()" does pretty much the same as
"Horde_Auth::getAuth()" did before and the move of the functionality
into the registry is absolutely fine.

For Kolab_Session this does however mean that the dependency on that
functionality gets further obscured. Something has to setup
$GLOBALS['registry'] before Kolab_Session is called into the mix.

At the same time I think the package would now need to pull in Core as
a dependency which I wouldn't like much either.

I think it is a cleaner solution to provide the Interfaces package. It
can be used to clearly define the communications between Core and the
other framework packages. This also allows to declare the dependencies
in an obvious manner and decouples low level libraries from the BIG
Core thing.
20 files changed:
framework/Core/lib/Horde/Registry.php
framework/Core/package.xml
framework/Interfaces/lib/Horde/Interfaces/Registry/Auth.php [new file with mode: 0644]
framework/Interfaces/package.xml [new file with mode: 0644]
framework/Kolab_Session/lib/Horde/Kolab/Session.php
framework/Kolab_Session/lib/Horde/Kolab/Session/Auth/Horde.php [deleted file]
framework/Kolab_Session/lib/Horde/Kolab/Session/Auth/Interface.php [deleted file]
framework/Kolab_Session/lib/Horde/Kolab/Session/Auth/Mock.php
framework/Kolab_Session/lib/Horde/Kolab/Session/Base.php
framework/Kolab_Session/lib/Horde/Kolab/Session/Decorator/Anonymous.php
framework/Kolab_Session/lib/Horde/Kolab/Session/Valid/Base.php
framework/Kolab_Session/lib/Horde/Kolab/Session/Valid/Decorator/Logged.php
framework/Kolab_Session/lib/Horde/Kolab/Session/Valid/Interface.php
framework/Kolab_Session/package.xml
framework/Kolab_Session/test/Horde/Kolab/Session/Class/Auth/HordeTest.php [deleted file]
framework/Kolab_Session/test/Horde/Kolab/Session/Class/Auth/MockTest.php
framework/Kolab_Session/test/Horde/Kolab/Session/Class/Valid/BaseTest.php
framework/Kolab_Session/test/Horde/Kolab/Session/Class/Valid/Decorator/LoggedTest.php
framework/Kolab_Session/test/Horde/Kolab/Session/Integration/ValidTest.php
framework/Kolab_Session/test/Horde/Kolab/Session/SessionTestCase.php