protected function constraintField(ConstraintFactory $where, $field, $value, $alias)
    {
        if ($field === $this->class->nodename) {
            $where->eq()->name($alias)->literal($value);
        } else {
            $where->eq()->field($alias.'.'.$field)->literal($value);
        }
    }
protected function constraintField(ConstraintFactory $where, $field, $value, $alias)
    {
        if ($field === $this->class->nodename) {
            $where->eq()->name($alias)->literal($value);
        } else {
            $where->eq()->field($alias.'.'.$field)->literal($value);
        }
    }
protected function constraintField ( ConstraintFactory $ where , $ field , $ value , $ alias ) { if ( $ field === $ this -> class -> nodename ) { $ where -> eq ( ) -> name ( $ alias ) -> literal ( $ value ) ; } else { $ where -> eq ( ) -> field ( $ alias . '.' . $ field ) -> literal ( $ value ) ; } }
Constraints a field for a given value.

@param ConstraintFactory $where
@param string            $field The field searched
@param mixed             $value The value to search for
@param string            $alias The alias used
Constraints a field for a given value .