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

Source for file options.php

Documentation is available at options.php

  1. <?php
  2. /**
  3.  * File containing the ezcConsoleStatusbarOptions 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.  * @package SignalSlot
  23.  * @version //autogentag//
  24.  * @license http://www.apache.org/licenses/LICENSE-2.0 Apache License, Version 2.0
  25.  * @filesource
  26.  */
  27.  
  28. /**
  29.  * Struct class to store the options of the ezcConsoleOutput class.
  30.  * This class stores the options for the {@link ezcSignalCollection} class.
  31.  *
  32.  * @property array(string) $signals 
  33.  *            The signals that the signal collection can throw. If this option
  34.  *            is set using a non-existent signal is considered an exceptional state.
  35.  *            If this option is not set or is set to null then using a non existent
  36.  *            signal is simply ignored.
  37.  *
  38.  * @package SignalSlot
  39.  * @version //autogen//
  40.  */
  41. {
  42.     /**
  43.      * Construct a new options object.
  44.      * Options are constructed from an option array by default. The constructor
  45.      * automatically passes the given options to the __set() method to set them
  46.      * in the class.
  47.      *
  48.      * @param array(string=>mixed) $options The initial options to set.
  49.      * @return void 
  50.      *
  51.      * @throws ezcBasePropertyNotFoundException
  52.      *          If a the value for the property options is not an instance of
  53.      * @throws ezcBaseValueException
  54.      *          If a the value for a property is out of range.
  55.      */
  56.     public function __constructarray $options array() )
  57.     {
  58.         $this->properties['signals'null;
  59.         parent::__construct$options );
  60.     }
  61.  
  62.     /**
  63.      * Option write access.
  64.      *
  65.      * @throws ezcBasePropertyNotFoundException
  66.      *          If a desired property could not be found.
  67.      * @throws ezcBaseSettingValueException
  68.      *          If a desired property value is out of range.
  69.      *
  70.      * @param string $key Name of the property.
  71.      * @param mixed $value  The value for the property.
  72.      * @ignore
  73.      */
  74.     public function __set$key$value )
  75.     {
  76.         switch $key )
  77.         {
  78.             case "signals":
  79.                 if $value != null && !is_array$value ) )
  80.                 {
  81.                     throw new ezcBaseSettingValueException$key$value'null, array(string)' );
  82.                 }
  83.                 break;
  84.             default:
  85.                 throw new ezcBaseSettingNotFoundException$key );
  86.         }
  87.         $this->properties[$key$value;
  88.     }
  89. }
  90.  
  91. ?>
Documentation generated by phpDocumentor 1.4.3