private function _stateAsString($code) { switch ($code) { case self::FREE: return 'free'; case self::TENTATIVE: return 'tentative'; case self::BUSY: return 'busy'; case self::OUTOFOFFICE: return 'outofoffice'; default: return 'unknown'; } }