src/LdapTools/Utilities/ArrayToOperator.php
public function getOperatorForSchema(LdapObjectSchema $schema, array $filter)
    {
        $operator = null;
        
        $categoryOperator = $this->getCategoryOperator($schema->getObjectCategory());
        $classOperator = $this->getClassOperator($schema->getObjectClass());

        if ($classOperator && $categoryOperator) {
            $operator = $this->filterBuilder->bAnd($categoryOperator, $classOperator);
        } elseif ($categoryOperator) {
            $operator = $categoryOperator;
        } elseif ($classOperator) {
            $operator = $classOperator;
        }
        
        return $this->getOperatorForArray($filter, $operator);
    }
public function getOperatorForSchema(LdapObjectSchema $schema, array $filter)
    {
        $operator = null;
        
        $categoryOperator = $this->getCategoryOperator($schema->getObjectCategory());
        $classOperator = $this->getClassOperator($schema->getObjectClass());

        if ($classOperator && $categoryOperator) {
            $operator = $this->filterBuilder->bAnd($categoryOperator, $classOperator);
        } elseif ($categoryOperator) {
            $operator = $categoryOperator;
        } elseif ($classOperator) {
            $operator = $classOperator;
        }
        
        return $this->getOperatorForArray($filter, $operator);
    }
public function getOperatorForSchema ( LdapObjectSchema $ schema , array $ filter ) { $ operator = null ; $ categoryOperator = $ this -> getCategoryOperator ( $ schema -> getObjectCategory ( ) ) ; $ classOperator = $ this -> getClassOperator ( $ schema -> getObjectClass ( ) ) ; if ( $ classOperator && $ categoryOperator ) { $ operator = $ this -> filterBuilder -> bAnd ( $ categoryOperator , $ classOperator ) ; } elseif ( $ categoryOperator ) { $ operator = $ categoryOperator ; } elseif ( $ classOperator ) { $ operator = $ classOperator ; } return $ this -> getOperatorForArray ( $ filter , $ operator ) ; }
Given a schema object and a filter array, construct the operator to be used for the schema.

@param LdapObjectSchema $schema
@param array $filter
@return BaseOperator
Given a schema object and a filter array construct the operator to be used for the schema .