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

## Source for file database.php

Documentation is available at database.php

1. <?php
2. /**
3. * This file contains the ezcWorkflowDatabaseOptions 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 WorkflowDatabaseTiein
23. * @version //autogentag//
24. * @license http://www.apache.org/licenses/LICENSE-2.0 Apache License, Version 2.0
25. * @filesource
26. */
28. /**
29. * Options class for ezcWorkflowDatabase.
30. *
31. * @property string $prefix
32. * The database table name prefix to be used.
33. *
34. * @package WorkflowDatabaseTiein
35. * @version //autogen//
36. */
37. class ezcWorkflowDatabaseOptions extends ezcBaseOptions
38. {
39. /**
40. * Properties.
41. *
42. * @var array(string=>mixed)
43. */
44. protected $properties = array(
45. 'prefix' => '',
46. );
48. /**
49. * Property write access.
50. *
51. * @param string $propertyName Name of the property.
52. * @param mixed $propertyValue The value for the property.
53. *
54. * @throws ezcBasePropertyNotFoundException
55. * If the the desired property is not found.
56. * @ignore
57. */
58. public function __set( $propertyName, $propertyValue )
59. {
60. switch ( $propertyName )
61. {
62. case 'prefix':
63. if ( ! is_string ( $propertyValue ) )
64. {
65. throw new ezcBaseValueException (
66. $propertyName,
67. $propertyValue,
68. 'string'
69. );
70. }
71. break;
72. default:
73. throw new ezcBasePropertyNotFoundException ( $propertyName );
74. }
75. $this-> properties [$propertyName] = $propertyValue;
76. }
77. }
78. ?>

Documentation generated by phpDocumentor 1.4.3