Apache Zeta Components Manual :: File Source for result_content_disposition.php

Source for file result_content_disposition.php

Documentation is available at result_content_disposition.php

  1. <?php
  2. /**
  3.  * File containing the ezcMvcResultContentDisposition class
  4.  *
  5.  * Licensed to the Apache Software Foundation (ASF) under one
  6.  * or more contributor license agreements.  See the NOTICE file
  7.  * distributed with this work for additional information
  8.  * regarding copyright ownership.  The ASF licenses this file
  9.  * to you under the Apache License, Version 2.0 (the
  10.  * "License"); you may not use this file except in compliance
  11.  * with the License.  You may obtain a copy of the License at
  12.  * 
  13.  *   http://www.apache.org/licenses/LICENSE-2.0
  14.  * 
  15.  * Unless required by applicable law or agreed to in writing,
  16.  * software distributed under the License is distributed on an
  17.  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
  18.  * KIND, either express or implied.  See the License for the
  19.  * specific language governing permissions and limitations
  20.  * under the License.
  21.  *
  22.  * @license http://www.apache.org/licenses/LICENSE-2.0 Apache License, Version 2.0
  23.  * @version //autogentag//
  24.  * @filesource
  25.  * @package MvcTools
  26.  */
  27.  
  28. /**
  29.  * This struct contains content disposition meta-data
  30.  *
  31.  * @package MvcTools
  32.  * @version //autogentag//
  33.  */
  34. {
  35.     /**
  36.      * The disposition type (inline or attachment)
  37.      *
  38.      * @var string 
  39.      */
  40.     public $type;
  41.  
  42.     /**
  43.      * The filename parameter, encoded as a UTF-8 string.
  44.      *
  45.      * @var string 
  46.      */
  47.     public $filename;
  48.  
  49.     /**
  50.      * The creation date parameter
  51.      *
  52.      * @var DateTime 
  53.      */
  54.     public $creationDate;
  55.  
  56.     /**
  57.      * The modification date parameter
  58.      *
  59.      * @var DateTime 
  60.      */
  61.     public $modificationDate;
  62.  
  63.     /**
  64.      * The read date parameter
  65.      *
  66.      * @var DateTime 
  67.      */
  68.     public $readDate;
  69.  
  70.     /**
  71.      * The size parameter
  72.      *
  73.      * @var int 
  74.      */
  75.     public $size;
  76.  
  77.     /**
  78.      * Constructs a new ezcMvcResultContent.
  79.      *
  80.      * @param string $type 
  81.      * @param string $filename 
  82.      * @param DateTime $creationDate 
  83.      * @param DateTime $modificationDate 
  84.      * @param DateTime $readDate 
  85.      * @param int $size 
  86.      */
  87.     public function __construct$type 'inline'$filename null,
  88.         DateTime $creationDate nullDateTime $modificationDate null,
  89.         DateTime $readDate null,
  90.         $size null )
  91.     {
  92.         $this->type = $type;
  93.         $this->filename = $filename;
  94.         $this->creationDate = $creationDate;
  95.         $this->modificationDate = $modificationDate;
  96.         $this->readDate = $readDate;
  97.         $this->size = $size;
  98.     }
  99.  
  100.     /**
  101.      * Returns a new instance of this class with the data specified by $array.
  102.      *
  103.      * $array contains all the data members of this class in the form:
  104.      * array('member_name'=>value).
  105.      *
  106.      * __set_state makes this class exportable with var_export.
  107.      * var_export() generates code, that calls this method when it
  108.      * is parsed with PHP.
  109.      *
  110.      * @param array(string=>mixed) $array 
  111.      * @return ezcMvcResultContent 
  112.      */
  113.     static public function __set_statearray $array )
  114.     {
  115.         return new ezcMvcResultContent$array['type']$array['filename'],
  116.             $array['creationDate']$array['modificationDate'],
  117.             $array['readDate']$array['size');
  118.     }
  119. }
  120. ?>
Documentation generated by phpDocumentor 1.4.3