configuration

# Class: LAMConfig

Source Location: /lib/config.inc

### Class Overview

This class manages .conf files.

### Constants

- ACCESS_ALL
- ACCESS_PASSWORD_CHANGE
- ACCESS_READ_ONLY
- LINE_SEPARATOR
- LOGIN_LIST
- LOGIN_SEARCH
- SAVE_FAIL
- SAVE_OK

### Methods

- __construct
- check_Passwd
- getAccessLevel
- getHttpAuthentication
- getLamProMailFrom
- getLamProMailIsHTML
- getLamProMailReplyTo
- getLamProMailSubject
- getLamProMailText
- getLoginMethod
- getLoginSearchFilter
- getLoginSearchSuffix
- getName
- getPath
- getUseTLS
- get_AccountModules
- get_ActiveTypes
- get_Admins
- get_Adminstring
- get_cacheTimeout
- get_cacheTimeoutSec
- get_defaultLanguage
- get_listAttributes
- get_moduleSettings
- get_scriptPath
- get_scriptRights
- get_scriptServers
- get_searchLimit
- get_ServerURL
- get_Suffix
- get_typeSettings
- isWritable
- save
- setAccessLevel
- setHttpAuthentication
- setLamProMailFrom
- setLamProMailIsHTML
- setLamProMailReplyTo
- setLamProMailSubject
- setLamProMailText
- setLoginMethod
- setLoginSearchFilter
- setLoginSearchSuffix
- setUseTLS
- set_AccountModules
- set_ActiveTypes
- set_Adminstring
- set_cacheTimeout
- set_defaultLanguage
- set_listAttributes
- set_moduleSettings
- set_Passwd
- set_scriptPath
- set_scriptRights
- set_scriptServers
- set_searchLimit
- set_ServerURL
- set_Suffix
- set_typeSettings

### Class Details

[line 170]
This class manages .conf files.
[ Top ]

### Class Methods

### constructor __construct [line 288]

`LAMConfig __construct( [integer $file = 0])`

Loads preferences from config file

#### Parameters:

integer | $file | Index number in config file array

[ Top ]

### method check_Passwd [line 577]

`boolean check_Passwd( String $password)`

Checks if the given password matches.

#### Tags:

return: | true, if matches
access: | public

#### Parameters:

String | $password |

[ Top ]

### method getAccessLevel [line 978]

`int getAccessLevel( )`

Returns the access level for this profile.

#### Tags:

return: | level
access: | public

[ Top ]

### method getHttpAuthentication [line 1034]

`String getHttpAuthentication( )`

Returns if HTTP authentication should be used.

#### Tags:

return: | use HTTP authentication ('true' or 'false')
access: | public

[ Top ]

### method getLamProMailFrom [line 1070]

`String getLamProMailFrom( )`

Returns the sender address for password reset mails.

#### Tags:

return: | mail address
access: | public

[ Top ]

### method getLamProMailIsHTML [line 1134]

`boolean getLamProMailIsHTML( )`

Returns if the password reset mail content should be treated as HTML.

#### Tags:

return: | HTML or text
access: | public

[ Top ]

### method getLamProMailReplyTo [line 1093]

`String getLamProMailReplyTo( )`

Returns the reply-to address for password reset mails.

#### Tags:

return: | mail address
access: | public

[ Top ]

### method getLamProMailSubject [line 1116]

`String getLamProMailSubject( )`

Returns the subject for password reset mails.

#### Tags:

return: | subject
access: | public

[ Top ]

### method getLamProMailText [line 1152]

`String getLamProMailText( )`

Returns the mail body for password reset mails.

#### Tags:

return: | body
access: | public

[ Top ]

### method getLoginMethod [line 998]

`String getLoginMethod( )`

Returns the login method.

#### Tags:

return: | login method
see: | LAMconfig::LOGIN_LIST
see: | LAMconfig::LOGIN_SEARCH
access: | public

[ Top ]

### method getLoginSearchFilter [line 1016]

`String getLoginSearchFilter( )`

Returns the login search filter.

#### Tags:

return: | search filter
access: | public

[ Top ]

### method getLoginSearchSuffix [line 1052]

`String getLoginSearchSuffix( )`

Returns the login search suffix.

#### Tags:

return: | suffix
access: | public

[ Top ]

### method getName [line 469]

`String getName( )`

Returns the name of the config file

#### Tags:

return: | name
access: | public

[ Top ]

### method getPath [line 487]

`string getPath( )`

Returns the path to the config file.

#### Tags:

return: | path on filesystem
access: | public

[ Top ]

### method getUseTLS [line 519]

`String getUseTLS( )`

Returns if TLS is activated.

#### Tags:

return: | yes or no
access: | public

[ Top ]

### method get_AccountModules [line 882]

`array get_AccountModules( string $scope)`

Returns an array of all selected account modules

#### Tags:

return: | user modules
access: | public

#### Parameters:

string | $scope | account type

[ Top ]

### method get_ActiveTypes [line 938]

`array get_ActiveTypes( )`

Returns a list of active account types.

#### Tags:

return: | list of types
access: | public

[ Top ]

### method get_Admins [line 543]

`array get_Admins( )`

Returns an array of string with all admin names

#### Tags:

return: | the admin names
access: | public

[ Top ]

### method get_Adminstring [line 552]

`string get_Adminstring( )`

Returns all admin users seperated by semicolons

#### Tags:

return: | the admin string
access: | public

[ Top ]

### method get_cacheTimeout [line 825]

`integer get_cacheTimeout( )`

Returns the LDAP cache timeout in minutes

#### Tags:

return: | cache time
access: | public

[ Top ]

### method get_cacheTimeoutSec [line 835]

`integer get_cacheTimeoutSec( )`

Returns the LDAP cache timeout in seconds

#### Tags:

return: | cache time
access: | public

[ Top ]

### method get_defaultLanguage [line 690]

`string get_defaultLanguage( )`

Returns the default language string

#### Tags:

return: | default language
access: | public

[ Top ]

### method get_listAttributes [line 664]

`string get_listAttributes( string $scope)`

Returns the list of attributes to show in user list

#### Tags:

return: | the attribute list
access: | public

#### Parameters:

string | $scope | account type

[ Top ]

### method get_moduleSettings [line 929]

`array get_moduleSettings( )`

Returns a list of saved module settings

#### Tags:

return: | list of settings: array(name => value)
access: | public

[ Top ]

### method get_scriptPath [line 711]

`string get_scriptPath( )`

Returns the path to the external script

#### Tags:

return: | script path
access: | public

[ Top ]

### method get_scriptRights [line 798]

`string get_scriptRights( )`

Returns the chmod value for new home directories.

#### Tags:

return: | rights
access: | public

[ Top ]

### method get_scriptServers [line 733]

`string get_scriptServers( )`

Returns the servers of the external script as a Array

#### Tags:

return: | script servers
access: | public

[ Top ]

### method get_searchLimit [line 858]

`integer get_searchLimit( )`

Returns the LDAP search limit.

#### Tags:

return: | search limit
access: | public

[ Top ]

### method get_ServerURL [line 498]

`string get_ServerURL( )`

Returns the server address as string

#### Tags:

return: | server address
access: | public

[ Top ]

### method get_Suffix [line 628]

`string get_Suffix( string $scope)`

Returns the LDAP suffix for the given account type

#### Tags:

return: | the LDAP suffix
access: | public

#### Parameters:

string | $scope | account type

[ Top ]

### method get_typeSettings [line 969]

`array get_typeSettings( )`

Returns a list of saved type settings

#### Tags:

return: | list of settings: array(name => value)
access: | public

[ Top ]

### method isWritable [line 478]

`boolean isWritable( )`

Returns if the file can be written on the filesystem.

#### Tags:

return: | true if file is writable
access: | public

[ Top ]

### method save [line 363]

`void save( )`

Saves preferences to config file

#### Tags:

access: | public

[ Top ]

### method setAccessLevel [line 987]

`void setAccessLevel( int $level)`

Sets the access level for this profile.

#### Tags:

access: | public

#### Parameters:

int | $level | level

[ Top ]

### method setHttpAuthentication [line 1043]

`void setHttpAuthentication( String $httpAuthentication)`

Specifies if HTTP authentication should be used.

#### Tags:

access: | public

#### Parameters:

String | $httpAuthentication | use HTTP authentication ('true' or 'false')

[ Top ]

### method setLamProMailFrom [line 1080]

`boolean setLamProMailFrom( String $lamProMailFrom)`

Sets the sender address for password reset mails.

#### Tags:

return: | true if address is valid
access: | public

#### Parameters:

String | $lamProMailFrom | mail address

[ Top ]

### method setLamProMailIsHTML [line 1143]

`void setLamProMailIsHTML( boolean $lamProMailIsHTML)`

Sets if the password reset mail content should be treated as HTML.

#### Tags:

access: | public

#### Parameters:

boolean | $lamProMailIsHTML |

[ Top ]

### method setLamProMailReplyTo [line 1103]

`boolean setLamProMailReplyTo( String $lamProMailReplyTo)`

Sets the reply-to address for password reset mails.

#### Tags:

return: | true if address is valid
access: | public

#### Parameters:

String | $lamProMailReplyTo | mail address

[ Top ]

### method setLamProMailSubject [line 1125]

`void setLamProMailSubject( String $lamProMailSubject)`

Sets the subject for password reset mails.

#### Tags:

access: | public

#### Parameters:

String | $lamProMailSubject | subject

[ Top ]

### method setLamProMailText [line 1161]

`void setLamProMailText( String $lamProMailText)`

Sets the mail body for password reset mails.

#### Tags:

access: | public

#### Parameters:

String | $lamProMailText | body

[ Top ]

### method setLoginMethod [line 1007]

`void setLoginMethod( String $loginMethod)`

Sets the login method.

#### Tags:

access: | public

#### Parameters:

String | $loginMethod |

[ Top ]

### method setLoginSearchFilter [line 1025]

`void setLoginSearchFilter( String $loginSearchFilter)`

Sets the login search filter.

#### Tags:

access: | public

#### Parameters:

String | $loginSearchFilter | search filter

[ Top ]

### method setLoginSearchSuffix [line 1061]

`void setLoginSearchSuffix( String $loginSearchSuffix)`

Sets the login search suffix.

#### Tags:

access: | public

#### Parameters:

String | $loginSearchSuffix | suffix

[ Top ]

### method setUseTLS [line 529]

`boolean setUseTLS( String $useTLS)`

Sets if TLS is activated.

#### Tags:

return: | true if $useTLS has correct format
access: | public

#### Parameters:

String | $useTLS | yes or no

[ Top ]

### method set_AccountModules [line 898]

`boolean set_AccountModules( array $modules, string $scope)`

Sets the selected account modules

#### Tags:

return: | true if $modules has correct format
access: | public

#### Parameters:

array | $modules | array with module names (not aliases!)
string | $scope | account type

[ Top ]

### method set_ActiveTypes [line 948]

`void set_ActiveTypes( array $types)`

Sets the list of active types.

#### Tags:

access: | public

#### Parameters:

array | $types | list of types

[ Top ]

### method set_Adminstring [line 562]

`boolean set_Adminstring( string $value)`

Sets the admin string

#### Tags:

return: | true if $value has correct format
access: | public

#### Parameters:

string | $value | new admin string that contains all admin users seperated by semicolons

[ Top ]

### method set_cacheTimeout [line 845]

`boolean set_cacheTimeout( integer $value)`

Sets the LDAP cache timeout in minutes (0,1,2,5,10,15)

#### Tags:

return: | true if $value has correct format
access: | public

#### Parameters:

integer | $value | new cache timeout

[ Top ]

### method set_defaultLanguage [line 700]

`boolean set_defaultLanguage( string $value)`

Sets the default language string

#### Tags:

return: | true if $value has correct format
access: | public

#### Parameters:

string | $value | new default language

[ Top ]

### method set_listAttributes [line 675]

`boolean set_listAttributes( string $value, string $scope)`

Sets the list of attributes to show in user list

#### Tags:

return: | true if $value has correct format
access: | public

#### Parameters:

string | $value | new attribute string
string | $scope | account type

[ Top ]

### method set_moduleSettings [line 918]

`boolean set_moduleSettings( array $settings)`

Sets the settings for the account modules.

#### Tags:

return: | true if $settings has correct format
access: | public

#### Parameters:

array | $settings | list of module setting array(name => value)

[ Top ]

### method set_Passwd [line 597]

`boolean set_Passwd( string $value)`

Sets the preferences wizard password

#### Tags:

return: | true if $value has correct format
access: | public

#### Parameters:

string | $value | new password

[ Top ]

### method set_scriptPath [line 721]

`boolean set_scriptPath( string $value)`

Sets the path to the external script

#### Tags:

return: | true if $value has correct format
access: | public

#### Parameters:

string | $value | new script path

[ Top ]

### method set_scriptRights [line 809]

`boolean set_scriptRights( string $chmod)`

Sets the rights for the home directory.

#### Tags:

return: | true if values has correct format
access: | public

#### Parameters:

string | $chmod | the rights

[ Top ]

### method set_scriptServers [line 743]

`boolean set_scriptServers( string $value)`

Sets the servers of the external script

#### Tags:

return: | true if $value has correct format
access: | public

#### Parameters:

string | $value | new script servers

[ Top ]

### method set_searchLimit [line 868]

`boolean set_searchLimit( integer $value)`

Sets the LDAP search limit.

#### Tags:

return: | true if $value has correct format
access: | public

#### Parameters:

integer | $value | new search limit

[ Top ]

### method set_ServerURL [line 508]

`boolean set_ServerURL( string $value)`

Sets the server address

#### Tags:

return: | true if $value has correct format
access: | public

#### Parameters:

string | $value | new server address

[ Top ]

### method set_Suffix [line 644]

`boolean set_Suffix( string $scope, string $value)`

Sets the LDAP suffix where accounts are saved

#### Tags:

return: | true if $value has correct format
access: | public

#### Parameters:

string | $scope | account type
string | $value | new LDAP suffix

[ Top ]

### method set_typeSettings [line 958]

`boolean set_typeSettings( array $settings)`

Sets the settings for the account types.

#### Tags:

return: | true if $settings has correct format
access: | public

#### Parameters:

array | $settings | list of type setting array(name => value)

[ Top ]

### Class Constants

#### ACCESS_ALL = 100

[line 173]

[ Top ]

#### ACCESS_PASSWORD_CHANGE = 20

[line 174]

[ Top ]

#### ACCESS_READ_ONLY = 0

[line 175]

[ Top ]

#### LINE_SEPARATOR = '+::+'

[line 186]

line separator
[ Top ]

#### LOGIN_LIST = 'list'

[line 182]

[ Top ]

#### LOGIN_SEARCH = 'search'

[line 183]

[ Top ]

#### SAVE_FAIL = 1

[line 179]

[ Top ]

#### SAVE_OK = 0

[line 178]

[ Top ]

Documentation generated on Tue, 22 Nov 2011 16:29:34 +0100 by phpDocumentor 1.4.1