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

Class: Site_Module

Source Location: /site.php

Class Overview

Module_Skeleton
   |
   --Site_Module



Variables

Methods



Class Details

[line 23]


[ Top ]


Class Variables

$user_srvc_cache =

[line 24]



Tags:

access:  protected

Type:   mixed


[ Top ]



Class Methods


method get_bandwidth_usage [line 119]

array get_bandwidth_usage( [int $mType = NULL])

array get_bandwidth_usage(string)



Tags:

return:  indexes begin, rollover, and threshold
privilege:  PRIVILEGE_SITE
access:  public


Parameters:

int   $mType   type of bandwidth usage to retrieve

[ Top ]

method get_site_services [line 199]

object Object get_site_services( )

object get_site_services()



Tags:

return:  containing all services and their respective values Calls the backend process to go through, tally up service information and return it as an unpacked object
privilege:  PRIVILEGE_SITE
access:  public


[ Top ]

method get_users [line 209]

void get_users( )

array get_users()



Tags:

privilege:  PRIVILEGE_SITE get_users_backend
access:  public


[ Top ]

method get_users_backend [line 226]

associative get_users_backend( )

array get_users_backend() Finds all applicable users created and returns an array consisting of their information from /etc/passwd. Indexed by username.



Tags:

return:  array of users with the key being the actual username The following indexes exist: -uid: user id -gid: group id (which will be the same as the uid of the site admin) -home: home directory of the user -shell: path to the shell used by the user
privilege:  PRIVILEGE_SITE|PRIVILEGE_SERVER_EXEC
throws:  FileError if either shadow or passwd files cannot be found
access:  public


[ Top ]

method get_user_count [line 86]

array get_user_count( )

array get_users () Finds the number of users currently on an account and the maximum number permitted.



Tags:

return:  associative array with indexes users and total depicting the current number of users on an account and the total number permitted
access:  public


[ Top ]

method get_user_count_backend [line 97]

int get_user_count_backend( )

int get_users_backend () Backend query to gather the number of users attached to a domain, excluding the base site administrator, so it will return the number of users in a site minus 1 to account for the primary user.



Tags:

return:  number of users on an account
access:  public


[ Top ]

method set_admin_email [line 158]

bool set_admin_email( string $mEmail)

bool set_admin_email(string email)



Tags:

return:  true on success, false on failure
privilege:  PRIVILEGE_SITE
access:  public


Parameters:

string   $mEmail   e-mail address to update the record to Backend PostgreSQL operation to update it in the db

[ Top ]

method set_admin_email_backend [line 172]

bool set_admin_email_backend( string $mEmail)

bool set_admin_email (string)



Tags:

return:  true on success, false on failure
privilege:  PRIVILEGE_SITE&PRIVILEGE_SERVER_EXEC Updates the record inside info/current/siteinfo
access:  public


Parameters:

string   $mEmail   e-mail address to update the account records to

[ Top ]

method user_service_enabled [line 53]

bool user_service_enabled( string $mUser, string $mSrvc)

bool user_service_enabled(string, string)



Tags:

access:  public


Parameters:

string   $mUser   username
string   $mSrvc   service name, possible values are ssh proftpd and imap

[ Top ]

method user_service_enabled_backend [line 61]

void user_service_enabled_backend( $mUser, $mSrvc)

bool user_service_enabled_backend (string, string)

user_service_enabled




Tags:

access:  public


Parameters:

   $mUser  
   $mSrvc  

[ Top ]


Documentation generated on Sat, 05 Jul 2008 04:00:45 -0400 by phpDocumentor 1.4.0