You are here

public static function vfsStream::newFile in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/mikey179/vfsStream/src/main/php/org/bovigo/vfs/vfsStream.php \org\bovigo\vfs\vfsStream::newFile()

returns a new file with given name

Parameters

string $name name of file to create:

int $permissions permissions of file to create:

Return value

vfsStreamFile

5 calls to vfsStream::newFile()
vfsStreamPrintVisitorTestCase::visitFileWritesFileNameToStream in vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/visitor/vfsStreamPrintVisitorTestCase.php
@test
vfsStreamTestCase::newFile in vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamTestCase.php
test to create a new file
vfsStreamTestCase::newFileWithDifferentPermissions in vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamTestCase.php
test to create a new file with non-default permissions
vfsStreamWrapperTestCase::unlinkReturnsFalseWhenFileDoesNotExist in vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperTestCase.php
@test @group issue_49
vfsStreamWrapperTestCase::unlinkReturnsFalseWhenFileDoesNotExistAndFileWithSameNameExistsInRoot in vendor/mikey179/vfsStream/src/test/php/org/bovigo/vfs/vfsStreamWrapperTestCase.php
@test @group issue_49

File

vendor/mikey179/vfsStream/src/main/php/org/bovigo/vfs/vfsStream.php, line 322

Class

vfsStream
Some utility methods for vfsStream.

Namespace

org\bovigo\vfs

Code

public static function newFile($name, $permissions = null) {
  return new vfsStreamFile($name, $permissions);
}