public function setAsKey($what)
    {
        switch ($what) {
            case self::CLASS_AS_KEY:
            case self::OFFSET_AS_KEY:
                $this->keytype = $what;
                break;
            default:
                $this->keytype = self::CLASS_AS_KEY;
                break;
        }
    }
public function setAsKey($what)
    {
        switch ($what) {
            case self::CLASS_AS_KEY:
            case self::OFFSET_AS_KEY:
                $this->keytype = $what;
                break;
            default:
                $this->keytype = self::CLASS_AS_KEY;
                break;
        }
    }
public function setAsKey ( $ what ) { switch ( $ what ) { case self :: CLASS_AS_KEY : case self :: OFFSET_AS_KEY : $ this -> keytype = $ what ; break ; default : $ this -> keytype = self :: CLASS_AS_KEY ; break ; } }
Decide what should be returned as key when iterated upon
Decide what should be returned as key when iterated upon