LiveUser
[ class tree: LiveUser ] [ index: LiveUser ] [ all elements ]

Class: LiveUser_Perm_Container_MDB2_Simple

Source Location: /LiveUser-0.11.0/Perm/Container/MDB2_Simple.php

Class Overview

LiveUser_Perm_Common
   |
   --LiveUser_Perm_Container_MDB2_Simple

Class LiveUser_Perm_Container_MDB2_Simple


Author(s):

Version:

  • $Id: MDB2_Simple.php,v 1.10 2004/04/25 15:55:09 lsmith Exp $

Variables

Methods


Child classes:

LiveUser_Perm_Container_MDB2_Medium
Class LiveUser_Perm_Container_MDB2_Medium

Inherited Variables

Inherited Methods

Class: LiveUser_Perm_Common

LiveUser_Perm_Common::LiveUser_Perm_Common()
Class constructor. Feel free to override in backend subclasses.
LiveUser_Perm_Common::checkLevel()
Checks if the current user has a certain right in a given area at the necessary level.
LiveUser_Perm_Common::checkRight()
Checks if the current user has a certain right in a given area.
LiveUser_Perm_Common::checkRightLevel()
Checks if the current user has a certain right in a given area with the sufficient level to gain access to a specific ressource in that area.
LiveUser_Perm_Common::disconnect()
properly disconnect from resources
LiveUser_Perm_Common::freeze()
store all properties in an array
LiveUser_Perm_Common::getProperty()
Function returns the inquired value if it exists in the class.
LiveUser_Perm_Common::getRights()
Returns a one-dimensional array with all rights assigned
LiveUser_Perm_Common::init()
Tries to find the user with the given user ID in the permissions container. Will read all permission data and return true on success.
LiveUser_Perm_Common::readGroupRights()
Reads all individual rights of current user into a two-dimensional array of this format: "GroupName" => "AreaName" -> "RightName"
LiveUser_Perm_Common::readRights()
Reads all rights of current user into a two-dimensional associative array, having the area names as the key of the 1st dimension.
LiveUser_Perm_Common::readUserRights()
Reads all individual rights of current user into a two-dimensional array of this format: AreaName => RightName -> Value
LiveUser_Perm_Common::unfreeze()
Reinitializes properties
LiveUser_Perm_Common::userExists()
Checks if a user with the given perm_user_id exists in the permission container and returns true on success.

Class Details

[line 47]
Class LiveUser_Perm_Container_MDB2_Simple

Simple MDB2-based complexity driver for LiveUser.

Description: The MDB2_Simple provides the following functionalities

  • users
  • userrights

  • Author: krausbn@php.net>
  • Version: $Id: MDB2_Simple.php,v 1.10 2004/04/25 15:55:09 lsmith Exp $


[ Top ]


Class Variables

$init_ok =  false

[line 90]

Indicates if backend module initialized correctly. If yes,

true, if not false. Backend module won't initialize if the init value (usually an object or resource handle that identifies the backend to be used) is not of the required type.

  • Access: public

Type:   boolean


[ Top ]

$prefix =  'liveuser_'

[line 78]

Table prefix Prefix for all db tables the container has.
  • Access: public

Type:   string


[ Top ]



Method Detail

LiveUser_Perm_Container_MDB2_Simple (Constructor)   [line 98]

void &LiveUser_Perm_Container_MDB2_Simple( &$connectOptions, mixed $connectOptions)

Constructor

Parameters:

mixed   $connectOptions   —  Array or PEAR::MDB2 object.
   &$connectOptions   — 

[ Top ]

disconnect   [line 170]

void disconnect( )

properly disconnect from resources
  • Access: public

Overrides LiveUser_Perm_Common::disconnect() (properly disconnect from resources)
[ Top ]

init   [line 138]

mixed init( string $uid)

Tries to find the user with the given user ID in the permissions container. Will read all permission data and return true on success.
  • Return: true on success or a PEAR_Error object
  • Access: public

Overridden in child classes as:

LiveUser_Perm_Container_MDB2_Medium::init()
Tries to find the user with the given user ID in the permissions container. Will read all permission data and return true on success.

Overrides LiveUser_Perm_Common::init() (Tries to find the user with the given user ID in the permissions container. Will read all permission data and return true on success.)

Parameters:

string   $uid   —  user identifier

[ Top ]

readRights   [line 219]

void readRights( )

Reads all rights of current user into an associative array.

Right => 1

  • Access: public

Overrides LiveUser_Perm_Common::readRights() (Reads all rights of current user into a two-dimensional associative array, having the area names as the key of the 1st dimension.)
[ Top ]

userExists   [line 188]

boolean userExists( integer $user_id)

LiveUser_Perm_Container_MDB2_Complex::userExists()

Checks if a user with the given perm_user_id exists in the permission container and returns true on success.

  • Return: true if the id was found, else false.
  • Access: public

Overrides LiveUser_Perm_Common::userExists() (Checks if a user with the given perm_user_id exists in the permission container and returns true on success.)

Parameters:

integer   $user_id   —  The users id in the permission table.

[ Top ]


Documentation generated on Mon, 11 Mar 2019 10:16:04 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.