public function toArray()
    {
        $data = array(
            self::ID         => $this->id,
            self::STATUS     => $this->status,
            self::START_TIME => $this->startTime->getTimestamp(),
        );

        if (! is_null($this->endTime)) {
            $data[self::END_TIME] = $this->endTime->getTimestamp();
        }

        return $data;
    }
public function toArray()
    {
        $data = array(
            self::ID         => $this->id,
            self::STATUS     => $this->status,
            self::START_TIME => $this->startTime->getTimestamp(),
        );

        if (! is_null($this->endTime)) {
            $data[self::END_TIME] = $this->endTime->getTimestamp();
        }

        return $data;
    }
public function toArray ( ) { $ data = array ( self :: ID => $ this -> id , self :: STATUS => $ this -> status , self :: START_TIME => $ this -> startTime -> getTimestamp ( ) , ) ; if ( ! is_null ( $ this -> endTime ) ) { $ data [ self :: END_TIME ] = $ this -> endTime -> getTimestamp ( ) ; } return $ data ; }
Return the Maintenance state as array, Datetime are converted to timestamp

@return array
Return the Maintenance state as array Datetime are converted to timestamp