filebackend: clean up some comments and remove unused FileBackendStoreOpHandle field
[lhc/web/wiklou.git] / includes / libs / ReplacementArray.php
index 02762f3..46f9358 100644 (file)
  * Wrapper around strtr() that holds replacements
  */
 class ReplacementArray {
-       private $data = false;
+       private $data = [];
 
        /**
         * Create an object with the specified replacement array
         * The array should have the same form as the replacement array for strtr()
         * @param array $data
         */
-       public function __construct( $data = [] ) {
+       public function __construct( array $data = [] ) {
                $this->data = $data;
        }
 
@@ -37,19 +37,19 @@ class ReplacementArray {
         * @return array
         */
        public function __sleep() {
-               return array( 'data' );
+               return [ 'data' ];
        }
 
        /**
         * Set the whole replacement array at once
         * @param array $data
         */
-       public function setArray( $data ) {
+       public function setArray( array $data ) {
                $this->data = $data;
        }
 
        /**
-        * @return array|bool
+        * @return array
         */
        public function getArray() {
                return $this->data;