Adldap\Connections\ConnectionInterface::connect PHP Méthode

connect() public méthode

Connects to the specified hostname using the specified port.
public connect ( string | array $hostname = [], integer $port = 389 ) : mixed
$hostname string | array
$port integer
Résultat mixed
    public function connect($hostname = [], $port = 389);

Usage Example

Exemple #1
0
 /**
  * {@inheritdoc}
  */
 public function setConnection(ConnectionInterface $connection = null)
 {
     // We'll create a standard connection if one isn't given.
     $this->connection = $connection ?: new Ldap();
     // Prepare the connection.
     $this->prepareConnection();
     // Instantiate the LDAP connection.
     $this->connection->connect($this->configuration->get('domain_controllers'), $this->configuration->get('port'));
     return $this;
 }
All Usage Examples Of Adldap\Connections\ConnectionInterface::connect