Class: ServiceFactory

Source Location: /CORE/system/classes/core/ServiceFactory.php

Class ServiceFactory

Class Overview

This core class returns Service Instances.

You should NOT instantiate Services directly, but request them via this class.

ATTENTION: This is a singleton, get an instance by calling:

  1. $services ServiceFactory::get();

Located in /CORE/system/classes/core/ServiceFactory.php [line 41]



		
				Author(s):
		
  • Kevin Papst
Information Tags:
Version:  $Id: ServiceFactory.php,v 1.4 2009/02/14 13:52:44 kpapst Exp $
Copyright:  Copyright (C) Kevin Papst
License:  GNU Public License

Methods

[ Top ]
Method Summary
static ServiceFactory   get()   Static getter, to receive an ServiceFactory instance.
Authenticator   getAuthenticator()   Gets the Authenticator instance to be used.
PrincipalService   getPrincipalService()   Gets the PrincipalService to be used.
mixed   getService()   Returns a configured Service.

[ Top ]
Methods
static method get  [line 70]

  static ServiceFactory get( )

Static getter, to receive an ServiceFactory instance.


API Tags:
Return:  the initialized ServiceFactory instance to be used


[ Top ]
getAuthenticator  [line 81]

  Authenticator getAuthenticator( )

Gets the Authenticator instance to be used.


API Tags:
Return:  the requested Authenticator instance


[ Top ]
getPrincipalService  [line 89]

  PrincipalService getPrincipalService( )

Gets the PrincipalService to be used.


API Tags:
Return:  the requested PrincipalService instance


[ Top ]
getService  [line 98]

  mixed getService( $name  )

Returns a configured Service.

If the Service could not be found null will be returned.

Parameters:
   $name: 

API Tags:
Return:  the service instance or null


[ Top ]