exchangeArray example

public function getTracedRequests(): array
    {
        return $this->tracedRequests->getArrayCopy();
    }

    public function reset(): void
    {
        if ($this->client instanceof ResetInterface) {
            $this->client->reset();
        }

        $this->tracedRequests->exchangeArray([]);
    }

    public function setLogger(LoggerInterface $logger): void
    {
        if ($this->client instanceof LoggerAwareInterface) {
            $this->client->setLogger($logger);
        }
    }

    public function withOptions(array $options)static
    {
        
return $this;
    }

    /** * Removes all stored plugins. * * @return Enlight_Plugin_PluginCollection */
    public function reset()
    {
        $this->plugins->exchangeArray([]);

        return $this;
    }
}
// Merge the values passed in from the classes array.         // The argument is cast to an array to support comma separated single         // values or one or more array arguments.         $classes[] = (array) $arg;
      }
      $classes = array_merge(...$classes);

      // Merge if there are values, just add them otherwise.       if (isset($this->storage['class']) && $this->storage['class'] instanceof AttributeArray) {
        // Merge the values passed in from the class value array.         $classes = array_merge($this->storage['class']->value()$classes);
        $this->storage['class']->exchangeArray($classes);
      }
      else {
        $this->offsetSet('class', $classes);
      }
    }

    return $this;
  }

  /** * Sets values for an attribute key. * * @param string $attribute * Name of the attribute. * @param string|array $value * Value(s) to set for the given attribute key. * * @return $this */
Home | Imprint | This part of the site doesn't use cookies.