## Apache Zeta Components Manual :: File Source for progressmonitor.php

## Source for file progressmonitor.php

Documentation is available at progressmonitor.php

1. <?php
2. /**
3. * File containing the ezcConsoleProgressMonitorOptions 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 ConsoleTools
23. * @version //autogentag//
24. * @license http://www.apache.org/licenses/LICENSE-2.0 Apache License, Version 2.0
25. * @filesource
26. */
28. /**
29. * Struct class to store the options of the ezcConsoleOutput class.
30. * This class stores the options for the {@link ezcConsoleOutput} class.
31. *
32. * @property string $formatString
33. * The format string to describe the complete progress monitor.
34. *
35. * @package ConsoleTools
36. * @version //autogen//
37. */
38. class ezcConsoleProgressMonitorOptions extends ezcBaseOptions
39. {
40. protected $properties = array(
41. 'formatString' => '%8.1f%% %s %s',
42. );
44. /**
45. * Option write access.
46. *
47. * @throws ezcBasePropertyNotFoundException
48. * If a desired property could not be found.
49. * @throws ezcBaseValueException
50. * If a desired property value is out of range.
51. *
52. * @param string $key Name of the property.
53. * @param mixed $value The value for the property.
54. * @ignore
55. */
56. public function __set( $key, $value )
57. {
58. switch ( $key )
59. {
60. case "formatString":
61. if ( is_string ( $value ) === false || strlen ( $value ) < 1 )
62. {
63. throw new ezcBaseValueException ( $key, $value, 'string, not empty' );
64. }
65. break;
66. default:
67. throw new ezcBasePropertyNotFoundException ( $key );
68. }
69. $this-> properties [$key] = $value;
70. }
71. }
73. ?>

Documentation generated by phpDocumentor 1.4.3