| @@ 37-48 (lines=12) @@ | ||
| 34 | * |
|
| 35 | * {@inheritDoc} |
|
| 36 | */ |
|
| 37 | public function isWritable()/*# : bool */ |
|
| 38 | { |
|
| 39 | foreach ($this->lookup_pool as $reg) { |
|
| 40 | if ($reg instanceof WritableInterface && |
|
| 41 | $reg->isWritable() |
|
| 42 | ) { |
|
| 43 | $this->setWritable($reg); |
|
| 44 | return true; |
|
| 45 | } |
|
| 46 | } |
|
| 47 | return false; |
|
| 48 | } |
|
| 49 | ||
| 50 | /** |
|
| 51 | * Override `setWritable()` in the WritableTrait |
|
| @@ 108-117 (lines=10) @@ | ||
| 105 | * @return $this |
|
| 106 | * @access protected |
|
| 107 | */ |
|
| 108 | protected function setRegistryWritableTrue() |
|
| 109 | { |
|
| 110 | foreach ($this->lookup_pool as $reg) { |
|
| 111 | if ($reg instanceof WritableInterface) { |
|
| 112 | $reg->setWritable(true); |
|
| 113 | return $this; |
|
| 114 | } |
|
| 115 | } |
|
| 116 | return $this; |
|
| 117 | } |
|
| 118 | } |
|
| 119 | ||