modules

# Class: sambaSamAccount Source Location: /lib/modules/sambaSamAccount.inc
### Class Overview
    baseModule
       |
       --sambaSamAccount
Manages the object class "sambaSamAccount" for users and hosts. | ### Variables $deactivated $hex2bitstring $noexpire $nopwd $rids $useunixpwd | ### Methods sambaSamAccount build_uploadAccounts checkSelfServiceOptions display_html_attributes display_html_logonHours display_html_sambaUserWorkstations display_html_time get_metaData get_pdfEntries get_profileOptions init load_attributes load_Messages load_profile module_complete module_ready process_attributes process_logonHours process_sambaUserWorkstations process_time save_attributes
### Inherited Variables #### Class: baseModule baseModule::$attributes baseModule::$base baseModule::$messages baseModule::$meta baseModule::$moduleSettings baseModule::$orig baseModule::$scope | ### Inherited Methods #### Class: baseModule baseModule::baseModule() Creates a new base module class baseModule::build_uploadAccounts() In this function the LDAP account is built up. baseModule::can_manage() Returns true if this module fits for the current scope. baseModule::checkSelfServiceOptions() Checks if all input values are correct and returns the LDAP commands which should be executed. baseModule::check_configOptions() Checks input values of module settings. baseModule::check_profileOptions() Checks input values of account profiles. baseModule::delete_attributes() Dummy function for modules which use no special options on account deletion. baseModule::display_html_delete() Dummy function for modules which do not print extra HTML code on account deletion. baseModule::doUploadPostActions() This function executes one post upload action. baseModule::getButtonStatus() Controls if the module button the account page is visible and activated. baseModule::getLDAPAliases() Returns a list of aliases for LDAP attributes. baseModule::getManagedAttributes() Returns a list of LDAP attributes which are managed by this module. baseModule::getManagedObjectClasses() Returns a list of managed object classes for this module. baseModule::getRequiredExtensions() Returns a list of required PHP extensions. baseModule::getSelfServiceFields() Returns a list of possible input fields and their descriptions Format: array(<field identifier> => <field description>) baseModule::getSelfServiceOptions() Returns the meta HTML code for each input field. baseModule::getSelfServiceSearchAttributes() Returns a list of possible search attributes for the self service. baseModule::get_alias() Returns an alias name for the module. baseModule::get_configOptions() Returns a list of elements for the configuration. baseModule::get_dependencies() This function returns a list with all depending and conflicting modules. baseModule::get_help() This function return the help entry array for a specific help id. Normally this->meta can be used. baseModule::get_ldap_filter() returns an LDAP filter for the account lists baseModule::get_metaData() Dummy function, meta data is provided by sub classes. baseModule::get_pdfFields() Returns an array with all fields available for this account type on the PDF output. This method may be overwritten by subclasses or it may be used by using entries in the $this->meta['PDF_fields'] array of the specific sub- class. baseModule::get_pdf_entries() Returns a hastable with all entries that may be printed out in the PDF. The baseModule::get_profileOptions() Returns a list of elements for the account profiles. baseModule::get_RDNAttributes() Returns a list of possible LDAP attributes which can be used to form the RDN. baseModule::get_scope() Returns the account type of this module (user, group, host) baseModule::get_uploadColumns() Returns an array containing all input columns for the file upload. baseModule::get_uploadPreDepends() Returns a list of module names which must be processed in building the account befor this module. baseModule::init() Initializes the module after it became part of an accountContainer baseModule::is_base_module() Returns true if this module is enough to provide a sensible account. baseModule::load_attributes() This function loads the LDAP attributes for this module. baseModule::load_Messages() This function fills the $messages variable with output messages from this module. baseModule::load_profile() Loads the values of an account profile into internal variables. baseModule::module_complete() This functions is used to check if all settings for this module have been made. baseModule::module_ready() This function is used to check if this module page can be displayed. baseModule::save_attributes() Returns a list of modifications which have to be made to the LDAP account.
### Class Details [line 38] Manages the object class "sambaSamAccount" for users and hosts. [ Top ] ### Class Variables #### $deactivated = [line 48] account deactivated?
Type: | mixed
[ Top ] #### $hex2bitstring = array('0' => '0000', '1' => '0001', '2' => '0010', '3' => '0011', '4' => '0100', '5' => '0101', '6' => '0110', '7' => '0111', '8' => '1000', '9' => '1001', 'A' => '1010', 'B' => '1011', 'C' => '1100', 'D' => '1101', 'E' => '1110', 'F' => '1111') [line 52] HEX to binary conversion table
Type: | mixed
[ Top ] #### $noexpire = [line 46] password does not expire?
Type: | mixed
[ Top ] #### $nopwd = [line 44] use no password?
Type: | mixed
[ Top ] #### $rids = [line 50] array of well known rids
Type: | mixed
[ Top ] #### $useunixpwd = [line 42] use Unix password as samba password?
Type: | mixed
[ Top ] ### Class Methods ### constructor sambaSamAccount [line 62]
`sambaSamAccount sambaSamAccount( string $scope)`
Creates a new sambaSamAccount object. #### Parameters:
string | $scope | account type (user, group, host)
[ Top ] ### method build_uploadAccounts [line 1392]
`array build_uploadAccounts( array $rawAccounts, array $ids, array &$partialAccounts)`
In this function the LDAP account is built up. #### Tags:
return: | list of error messages if any
Overrides baseModule::build_uploadAccounts() (In this function the LDAP account is built up.) #### Parameters:
array | $rawAccounts | list of hash arrays (name => value) from user input
array | $partialAccounts | list of hash arrays (name => value) which are later added to LDAP
array | $ids | list of IDs for column position (e.g. "posixAccount_uid" => 5)
[ Top ] ### method checkSelfServiceOptions [line 1726]
`array checkSelfServiceOptions( string $fields, array $attributes)`
Checks if all input values are correct and returns the LDAP commands which should be executed. #### Tags:
return: | messages and LDAP commands (array('messages' => array(), 'add' => array(), 'del' => array(), 'mod' => array()))
Overrides baseModule::checkSelfServiceOptions() (Checks if all input values are correct and returns the LDAP commands which should be executed.) #### Parameters:
string | $fields | input fields
array | $attributes | LDAP attributes
[ Top ] ### method display_html_attributes [line 828]
`void display_html_attributes( )`
[ Top ] ### method display_html_logonHours [line 1042]
`array display_html_logonHours( )`
This function will create the HTML page to edit logon hours. #### Tags:
return: | meta HTML code
[ Top ] ### method display_html_sambaUserWorkstations [line 1008]
`void display_html_sambaUserWorkstations( )`
[ Top ] ### method display_html_time [line 1105]
`array display_html_time( )`
This function will create the meta HTML code to show a page to change time values. #### Tags:
return: | meta HTML code
[ Top ] ### method get_metaData [line 113]
`array get_metaData( )`
Returns meta data that is interpreted by parent class #### Tags:
return: | array with meta data
Overrides baseModule::get_metaData() (Dummy function, meta data is provided by sub classes.) [ Top ] ### method get_pdfEntries [line 1373]
`array get_pdfEntries( )`
Returns the PDF entries for this module. #### Tags:
return: | list of possible PDF entries
[ Top ] ### method get_profileOptions [line 1156]
`profile get_profileOptions( )`
Returns a list of elements for the account profiles. #### Tags:
return: | elements
Overrides baseModule::get_profileOptions() (Returns a list of elements for the account profiles.) [ Top ] ### method init [line 462]
`void init( string $base)`
Initializes the module after it became part of an accountContainer Overrides baseModule::init() (Initializes the module after it became part of an accountContainer) #### Parameters:
string | $base | the name of the accountContainer object ($_SESSION[$base])
[ Top ] ### method load_attributes [line 503]
`void load_attributes( mixed $attr)`
Overrides baseModule::load_attributes() (This function loads the LDAP attributes for this module.) [ Top ] ### method load_Messages [line 74]
`void load_Messages( )`
this functin fills the error message array with messages Overrides baseModule::load_Messages() (This function fills the $messages variable with output messages from this module.) [ Top ] ### method load_profile [line 1281]
`void load_profile( array $profile)`
Loads the values of an account profile into internal variables. Overrides baseModule::load_profile() (Loads the values of an account profile into internal variables.) #### Parameters:
array | $profile | hash array with profile values (identifier => value)
[ Top ] ### method module_complete [line 494]
`boolean module_complete( )`
This functions is used to check if all settings for this module have been made. #### Tags:
return: | true, if settings are complete
Overrides baseModule::module_complete() (This functions is used to check if all settings for this module have been made.) [ Top ] ### method module_ready [line 482]
`boolean module_ready( )`
This function is used to check if this module page can be displayed. It returns false if a module depends on data from other modules which was not yet entered. #### Tags:
return: | true, if page can be displayed
Overrides baseModule::module_ready() (This function is used to check if this module page can be displayed.) [ Top ] ### method process_attributes [line 551]
`array process_attributes( )`
Processes user input of the primary module page. It checks if all input values are correct and updates the associated LDAP attributes. #### Tags:
return: | list of info/error messages
[ Top ] ### method process_logonHours [line 762]
`array process_logonHours( )`
Processes user input of the logon hours page. It checks if all input values are correct and updates the associated LDAP attributes. #### Tags:
return: | list of info/error messages
[ Top ] ### method process_sambaUserWorkstations [line 712]
`array process_sambaUserWorkstations( )`
Processes user input of the primary module page. It checks if all input values are correct and updates the associated LDAP attributes. #### Tags:
return: | list of info/error messages
[ Top ] ### method process_time [line 788]
`array process_time( )`
Processes user input of the time selection page. #### Tags:
return: | list of info/error messages
[ Top ] ### method save_attributes [line 523]
`void save_attributes( )`
Overrides baseModule::save_attributes() (Returns a list of modifications which have to be made to the LDAP account.) [ Top ] Documentation generated on Wed, 15 Nov 2006 18:01:03 +0100 by phpDocumentor 1.2.3