Swat/SwatTableViewOrderableColumn.php
private function setDirectionByString($direction)
    {
        $direction = mb_strtolower($direction);

        switch ($direction) {
            case 'ascending':
            case 'asc':
                $this->direction = self::ORDER_BY_DIR_ASCENDING;
                break;

            case 'descending':
            case 'desc':
                $this->direction = self::ORDER_BY_DIR_DESCENDING;
                break;

            default:
                $this->direction = self::ORDER_BY_DIR_NONE;
        }
    }
private function setDirectionByString($direction)
    {
        $direction = mb_strtolower($direction);

        switch ($direction) {
            case 'ascending':
            case 'asc':
                $this->direction = self::ORDER_BY_DIR_ASCENDING;
                break;

            case 'descending':
            case 'desc':
                $this->direction = self::ORDER_BY_DIR_DESCENDING;
                break;

            default:
                $this->direction = self::ORDER_BY_DIR_NONE;
        }
    }
private function setDirectionByString ( $ direction ) { $ direction = mb_strtolower ( $ direction ) ; switch ( $ direction ) { case 'ascending' : case 'asc' : $ this -> direction = self :: ORDER_BY_DIR_ASCENDING ; break ; case 'descending' : case 'desc' : $ this -> direction = self :: ORDER_BY_DIR_DESCENDING ; break ; default : $ this -> direction = self :: ORDER_BY_DIR_NONE ; } }
Sets direction of ordering by a string

Sets the current ordering direction of this column.

@param string $direction ordering direction as a string. The direction
is case insensitive and may be the short form
'asc' or 'desc' or the long form 'ascending'
or 'descending'.
Sets direction of ordering by a string