Kraken\Filesystem\FilesystemInterface::create PHP Method

create() public method

Create a new file or overwrite existing one.
public create ( string $path, string $contents )
$path string
$contents string
    public function create($path, $contents);

Usage Example

コード例 #1
0
 /**
  * Copy temporary process allocation data to persistent storage.
  *
  * @param string[] $with
  * @throws ReadException
  */
 private function updateStorage($with = [])
 {
     $data = [];
     foreach ($this->processes as $processAlias => $process) {
         $data[$processAlias] = $process;
     }
     $data = array_merge($data, $with);
     $this->fs->create($this->fsPath, json_encode($data));
 }
All Usage Examples Of Kraken\Filesystem\FilesystemInterface::create