API Documentation

Gdata/Gapps/Extension/Login.php

Includes Classes 
category
Zend
copyright
Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
license
http://framework.zend.com/license/new-bsd New BSD License
package
Zend_Gdata
subpackage
Gapps
version
$Id: Login.php 20096 2010-01-06 02:05:09Z bkarwin $
Classes
Zend_Gdata_Gapps_Extension_Login

Description

Zend Framework

LICENSE

This source file is subject to the new BSD license that is bundled with this package in the file LICENSE.txt. It is also available through the world-wide-web at this URL: http://framework.zend.com/license/new-bsd If you did not receive a copy of the license and are unable to obtain it through the world-wide-web, please send an email to license@zend.com so we can send you a copy immediately.

Zend_Gdata_Gapps_Extension_Login

Extends from
Zend_Gdata_Extension
category
Zend
copyright
Copyright (c) 2005-2010 Zend Technologies USA Inc. (http://www.zend.com)
license
http://framework.zend.com/license/new-bsd New BSD License
package
Zend_Gdata
subpackage
Gapps
Properties
$_rootNamespace
$_rootElement
$_username
$_password
$_hashFunctionName
$_admin
$_agreedToTerms
$_suspended
$_changePasswordAtNextLogin
Methods
__construct
getDOM
takeAttributeFromDOM
getUsername
setUsername
getPassword
setPassword
getHashFunctionName
setHashFunctionName
getAdmin
setAdmin
getAgreedToTerms
setAgreedToTerms
getSuspended
setSuspended
getChangePasswordAtNextLogin
setChangePasswordAtNextLogin
__toString

Description

Represents the apps:login element used by the Apps data API. This class is used to describe properties of a user, and is usually contained within instances of Zene_Gdata_Gapps_UserEntry or any other class which is linked to a particular username.

Properties

$_admin

boolean $_admin = 'null'

True if the user has administrative rights for this domain, false otherwise.

Details

$_admin
boolean
visibility
protected
default
null
final
false
static
false

$_agreedToTerms

boolean. $_agreedToTerms = 'null'

True if the user has agreed to the terms of service for Google Apps, false otherwise.

Details

$_agreedToTerms
boolean.
visibility
protected
default
null
final
false
static
false

$_changePasswordAtNextLogin

boolean $_changePasswordAtNextLogin = 'null'

True if the user will be required to change their password at their next login, false otherwise.

Details

$_changePasswordAtNextLogin
boolean
visibility
protected
default
null
final
false
static
false

$_hashFunctionName

string $_hashFunctionName = 'null'

Specifies whether the password stored in _password is in cleartext or is an SHA-1 digest of a password. If the password is cleartext, then this should be null. If the password is an SHA-1 digest, then this should be set to 'SHA-1'.

At the time of writing, no other hash functions are supported

Details

$_hashFunctionName
string
visibility
protected
default
null
final
false
static
false

$_password

string $_password = 'null'

The password for the user. May be in cleartext or as an SHA-1 digest, depending on the value of _hashFunctionName.

Details

$_password
string
visibility
protected
default
null
final
false
static
false

$_rootElement

 $_rootElement = 'login'

Details

visibility
protected
default
login
final
false
static
false

$_rootNamespace

 $_rootNamespace = 'apps'

Details

visibility
protected
default
apps
final
false
static
false

$_suspended

boolean $_suspended = 'null'

True if this user has been suspended, false otherwise.

Details

$_suspended
boolean
visibility
protected
default
null
final
false
static
false

$_username

string $_username = 'null'

The username for this user. This is used as the user's email address and when logging in to Google Apps-hosted services.

Details

$_username
string
visibility
protected
default
null
final
false
static
false

Methods

__construct

__construct( string $username = null, string $password = null, string $hashFunctionName = null, boolean $admin = null, boolean $suspended = null, boolean $changePasswordAtNextLogin = null, boolean $agreedToTerms = null ) :

Constructs a new Zend_Gdata_Gapps_Extension_Login object.

Arguments
$username
string
(optional) The username to be used for this login.
$password
string
(optional) The password to be used for this login.
$hashFunctionName
string
(optional) The name of the hash function used to protect the password, or null if no has function has been applied. As of this writing, the only valid values are 'SHA-1' or null.
$admin
boolean
(optional) Whether the user is an administrator or not.
$suspended
boolean
(optional) Whether this login is suspended or not.
$changePasswordAtNextLogin
boolean
(optional) Whether the user is required to change their password at their next login.
$agreedToTerms
boolean
(optional) Whether the user has agreed to the terms of service.
Details
visibility
public
final
false
static
false

__toString

__toString( ) :

Magic toString method allows using this directly via echo Works best in PHP >= 4.2.0

Details
visibility
public
final
false
static
false

getAdmin

getAdmin( ) : boolean

Get the value for this element's admin attribute.

Output
boolean
The requested attribute.
Details
visibility
public
final
false
static
false
see
setAdmin
throws

getAgreedToTerms

getAgreedToTerms( ) : boolean

Get the value for this element's agreedToTerms attribute.

Output
boolean
The requested attribute.
Details
visibility
public
final
false
static
false
see
setAgreedToTerms
throws

getChangePasswordAtNextLogin

getChangePasswordAtNextLogin( ) : boolean

Get the value for this element's changePasswordAtNextLogin attribute.

Output
boolean
The requested attribute.
Details
visibility
public
final
false
static
false
see
setChangePasswordAtNextLogin
throws

getDOM

getDOM( DOMDocument $doc = null,  $majorVersion = 1,  $minorVersion = null ) : DOMElement

Retrieves a DOMElement which corresponds to this element and all child properties. This is used to build an entry back into a DOM and eventually XML text for sending to the server upon updates, or for application storage/persistence.

Arguments
$doc
DOMDocument
The DOMDocument used to construct DOMElements
$majorVersion
$minorVersion
Output
DOMElement
The DOMElement representing this element and all child properties.
Details
visibility
public
final
false
static
false

getHashFunctionName

getHashFunctionName( ) : string

Get the value for this element's hashFunctionName attribute.

Output
string
The requested attribute.
Details
visibility
public
final
false
static
false
see
setHashFunctionName

getPassword

getPassword( ) : string

Get the value for this element's password attribute.

Output
string
The requested attribute.
Details
visibility
public
final
false
static
false
see
setPassword

getSuspended

getSuspended( ) : boolean

Get the value for this element's suspended attribute.

Output
boolean
The requested attribute.
Details
visibility
public
final
false
static
false
see
setSuspended
throws

getUsername

getUsername( ) : string

Get the value for this element's username attribute.

Output
string
The attribute being modified.
Details
visibility
public
final
false
static
false
see
setUsername

setAdmin

setAdmin( boolean $value ) : Zend_Gdata_Gapps_Extension_Login

Set the value for this element's admin attribute. This indicates whether this user is an administrator for this domain.

Arguments
$value
boolean
The desired value for this attribute.
Output
Zend_Gdata_Gapps_Extension_Login
Provides a fluent interface.
Details
visibility
public
final
false
static
false
throws

setAgreedToTerms

setAgreedToTerms( boolean $value ) : Zend_Gdata_Gapps_Extension_Login

Set the value for this element's agreedToTerms attribute. This indicates whether this user has agreed to the terms of service.

Arguments
$value
boolean
The desired value for this attribute.
Output
Zend_Gdata_Gapps_Extension_Login
Provides a fluent interface.
Details
visibility
public
final
false
static
false
throws

setChangePasswordAtNextLogin

setChangePasswordAtNextLogin( boolean $value ) : Zend_Gdata_Gapps_Extension_Login

Set the value for this element's changePasswordAtNextLogin attribute.

If true, the user will be forced to set a new password the next time they login.

Arguments
$value
boolean
The desired value for this attribute.
Output
Zend_Gdata_Gapps_Extension_Login
Provides a fluent interface.
Details
visibility
public
final
false
static
false
throws

setHashFunctionName

setHashFunctionName( string $value ) : Zend_Gdata_Gapps_Extension_Login

Set the value for this element's hashFunctionName attribute. This indicates whether the password supplied with setPassword() is in plaintext or has had a hash function applied to it. If null, plaintext is assumed. As of this writing, the only valid hash function is 'SHA-1'.

Arguments
$value
string
The desired value for this attribute.
Output
Zend_Gdata_Gapps_Extension_Login
Provides a fluent interface.
Details
visibility
public
final
false
static
false

setPassword

setPassword( string $value ) : Zend_Gdata_Gapps_Extension_Login

Set the value for this element's password attribute. As of this writing, this can be either be provided as plaintext or hashed using the SHA-1 algorithm for protection. If using a hash function, this must be indicated by calling setHashFunctionName().

Arguments
$value
string
The desired value for this attribute.
Output
Zend_Gdata_Gapps_Extension_Login
Provides a fluent interface.
Details
visibility
public
final
false
static
false

setSuspended

setSuspended( boolean $value ) : Zend_Gdata_Gapps_Extension_Login

Set the value for this element's suspended attribute. If true, the user will not be able to login to this domain until unsuspended.

Arguments
$value
boolean
The desired value for this attribute.
Output
Zend_Gdata_Gapps_Extension_Login
Provides a fluent interface.
Details
visibility
public
final
false
static
false
throws

setUsername

setUsername( string $value ) : Zend_Gdata_Gapps_Extension_Login

Set the value for this element's username attribute. This string is used to uniquely identify the user in this domian and is used to form this user's email address.

Arguments
$value
string
The desired value for this attribute.
Output
Zend_Gdata_Gapps_Extension_Login
Provides a fluent interface.
Details
visibility
public
final
false
static
false

takeAttributeFromDOM

takeAttributeFromDOM( DOMNode $attribute ) :

Given a DOMNode representing an attribute, tries to map the data into instance members. If no mapping is defined, the name and value are stored in an array.

Arguments
$attribute
DOMNode
The DOMNode attribute needed to be handled
Details
visibility
protected
final
false
static
false
throws
Documentation was generated by DocBlox.