## Class TAuthorizationRuleCollection

Description

TAuthorizationRuleCollection class.

TAuthorizationRuleCollection represents a collection of authorization rules TAuthorizationRule. To check if a user is allowed, call isUserAllowed.

- since: 3.0
- version: $Id: TAuthorizationRule.php 2294 2007-10-02 13:38:13Z xue $
- author: Qiang Xue <qiang.xue@gmail.com>

Located in /Security/TAuthorizationRule.php (line 256)

    TComponent
       |
       --TList
          |
          --TAuthorizationRuleCollection

Method Summary
void insertAt (integer $index, mixed $item)
boolean isUserAllowed (IUser $user, string $verb, string $ip)
Methods
insertAt (line 288)

Inserts an item at the specified position.

This overrides the parent implementation by performing additional operations for each newly added TAuthorizationRule object.

- access: public
- throws: TInvalidDataTypeException if the item to be inserted is not a TAuthorizationRule object.

void insertAt (integer $index, mixed $item)

- integer $index: the specified position.
- mixed $item: new item

Redefinition of:

TList::insertAt()
  Inserts an item at the specified position.

isUserAllowed (line 264)

- return: whether the user is allowed
- access: public

boolean isUserAllowed (IUser $user, string $verb, string $ip)

- IUser $user: the user to be authorized
- string $verb: verb, can be empty, 'post' or 'get'.
- string $ip: the request IP address

#### Inherited Methods

Inherited From TList

> TList::__construct()
> TList::add()
> TList::clear()
> TList::contains()
> TList::copyFrom()
> TList::count()
> TList::getCount()
> TList::getIterator()
> TList::getReadOnly()
> TList::indexOf()
> TList::insertAt()
> TList::itemAt()
> TList::mergeWith()
> TList::offsetExists()
> TList::offsetGet()
> TList::offsetSet()
> TList::offsetUnset()
> TList::remove()
> TList::removeAt()
> TList::setReadOnly()
> TList::toArray()

Inherited From TComponent

> TComponent::addParsedObject()
> TComponent::attachEventHandler()
> TComponent::canGetProperty()
> TComponent::canSetProperty()
> TComponent::createdOnTemplate()
> TComponent::detachEventHandler()
> TComponent::evaluateExpression()
> TComponent::evaluateStatements()
> TComponent::getEventHandlers()
> TComponent::getSubProperty()
> TComponent::hasEvent()
> TComponent::hasEventHandler()
> TComponent::hasProperty()
> TComponent::raiseEvent()
> TComponent::setSubProperty()
> TComponent::__get()
> TComponent::__set()

Documentation generated on Mon, 21 Apr 2008 11:30:43 -0400 by phpDocumentor 1.3.0RC4