trait StorageCopyTrait (View source)

Utility trait to copy configuration from one storage to another.

Methods

static 
replaceStorageContents(StorageInterface $source, StorageInterface $target)

Copy the configuration from one storage to another and remove stale items.

Details

static protected replaceStorageContents(StorageInterface $source, StorageInterface $target)

Copy the configuration from one storage to another and remove stale items.

This method empties target storage and copies all collections from source. Configuration is only copied and not imported, should not be used with the active storage as the target.

Parameters

StorageInterface $source

The configuration storage to copy from.

StorageInterface $target

The configuration storage to copy to.