PHP Class LdapTools\Object\LdapObjectCreator

Author: Chad Sikorra ([email protected])
Afficher le fichier Open project: ldaptools/ldaptools Class Usage Examples

Protected Properties

Свойство Type Description
$attributes array
$connection LdapTools\Connection\LdapConnectionInterface
$container string
$dispatcher LdapTools\Event\EventDispatcherInterface
$dn An explicitly set distinguished name.
$hydrator LdapTools\Hydrator\OperationHydrator
$parameters Any explicitly set parameter values are stored here.
$schema LdapTools\Schema\LdapObjectSchema
$schemaFactory LdapTools\Factory\LdapObjectSchemaFactory
$server A specific server to execute the LDAP object creation against.

Méthodes publiques

Méthode Description
__construct ( LdapTools\Connection\LdapConnectionInterface $connection, LdapObjectSchemaFactory $schemaFactory, LdapTools\Event\EventDispatcherInterface $dispatcher )
create ( string | LdapObjectSchema $type ) Specify the object type to create. Either by its string name type from the schema of the LdapObjectSchema.
createComputer ( ) Shorthand method for creating a computer LDAP object.
createContact ( ) Shorthand method for creating a contact LDAP object.
createGroup ( ) Shorthand method for creating a group LDAP object.
createOU ( ) Shorthand method for creating an OU LDAP object.
createUser ( ) Shorthand method for creating a generic user type.
execute ( ) Add the object with the selected attributes into LDAP.
getServer ( ) : string | null Get an explicit LDAP server to execute against, if any is set.
in ( $container ) Sets the OU/container the object will be created in.
setDn ( string $dn ) Explicitly set the DN to use when adding it to LDAP.
setParameter ( string $parameter, mixed $value ) Set a value for a specific placeholder in the schema, or in any values you added (ie. Anything enclosed within percentage signs such as %placeholder%).
setServer ( string $server ) Set an explicit LDAP server to execute against.
with ( array $attributes ) Sets the attributes the object will be created with.

Méthodes protégées

Méthode Description
getAddOperation ( ) : AddOperation Get the add operation and take care of the hydration process.
triggerAfterCreationEvent ( AddOperation $operation ) Trigger a LDAP object after creation event.
triggerBeforeCreationEvent ( ) Trigger a LDAP object before creation event.

Method Details

__construct() public méthode

public __construct ( LdapTools\Connection\LdapConnectionInterface $connection, LdapObjectSchemaFactory $schemaFactory, LdapTools\Event\EventDispatcherInterface $dispatcher )
$connection LdapTools\Connection\LdapConnectionInterface
$schemaFactory LdapTools\Factory\LdapObjectSchemaFactory
$dispatcher LdapTools\Event\EventDispatcherInterface

create() public méthode

Specify the object type to create. Either by its string name type from the schema of the LdapObjectSchema.
public create ( string | LdapObjectSchema $type )
$type string | LdapTools\Schema\LdapObjectSchema

createComputer() public méthode

Shorthand method for creating a computer LDAP object.
public createComputer ( )

createContact() public méthode

Shorthand method for creating a contact LDAP object.
public createContact ( )

createGroup() public méthode

Shorthand method for creating a group LDAP object.
public createGroup ( )

createOU() public méthode

Shorthand method for creating an OU LDAP object.
public createOU ( )

createUser() public méthode

Shorthand method for creating a generic user type.
public createUser ( )

execute() public méthode

Add the object with the selected attributes into LDAP.
public execute ( )

getAddOperation() protected méthode

Get the add operation and take care of the hydration process.
protected getAddOperation ( ) : AddOperation
Résultat LdapTools\Operation\AddOperation

getServer() public méthode

Get an explicit LDAP server to execute against, if any is set.
public getServer ( ) : string | null
Résultat string | null

in() public méthode

Sets the OU/container the object will be created in.
public in ( $container )
$container

setDn() public méthode

Explicitly set the DN to use when adding it to LDAP.
public setDn ( string $dn )
$dn string

setParameter() public méthode

Set a value for a specific placeholder in the schema, or in any values you added (ie. Anything enclosed within percentage signs such as %placeholder%).
public setParameter ( string $parameter, mixed $value )
$parameter string
$value mixed

setServer() public méthode

Set an explicit LDAP server to execute against.
public setServer ( string $server )
$server string

triggerAfterCreationEvent() protected méthode

Trigger a LDAP object after creation event.
protected triggerAfterCreationEvent ( AddOperation $operation )
$operation LdapTools\Operation\AddOperation

triggerBeforeCreationEvent() protected méthode

Trigger a LDAP object before creation event.

with() public méthode

Sets the attributes the object will be created with.
public with ( array $attributes )
$attributes array

Property Details

$attributes protected_oe property

protected array $attributes
Résultat array

$connection protected_oe property

protected LdapConnectionInterface,LdapTools\Connection $connection
Résultat LdapTools\Connection\LdapConnectionInterface

$container protected_oe property

protected string $container
Résultat string

$dispatcher protected_oe property

protected EventDispatcherInterface,LdapTools\Event $dispatcher
Résultat LdapTools\Event\EventDispatcherInterface

$dn protected_oe property

An explicitly set distinguished name.
protected $dn

$hydrator protected_oe property

protected OperationHydrator,LdapTools\Hydrator $hydrator
Résultat LdapTools\Hydrator\OperationHydrator

$parameters protected_oe property

Any explicitly set parameter values are stored here.
protected $parameters

$schema protected_oe property

protected LdapObjectSchema,LdapTools\Schema $schema
Résultat LdapTools\Schema\LdapObjectSchema

$schemaFactory protected_oe property

protected LdapObjectSchemaFactory,LdapTools\Factory $schemaFactory
Résultat LdapTools\Factory\LdapObjectSchemaFactory

$server protected_oe property

A specific server to execute the LDAP object creation against.
protected $server