Document Library



( ZN >= 5.4.5 )

File :: and Folder :: is a library that is created by ordering library methods to be used sequentially according to a specific target information. Hence, the methods of these two librarians are used.

 

# Methods


this target ( String $ target )
Mixed apply ( Void )

 

# Target ( ZN >= 5.4.5 )


Used to specify file or directory information. If the path contains index information, the path information must be followed by a slash (/) .

Parameters

String $ path Road information. If the route information indicates a sequence, the end of the route information/ .
return this

uses

echo Document::target('example.txt')
             ->create()
             ->write('Hello Body!')
             ->read()
             ->apply();
Hello Body!

Working with Directories

In order for the target to be able to express the index, the parameter written to the target ()/ should be.

echo Document::target('ExampleDir/')
             ->create()
             ->permission(0777)
             ->apply();
true

 

# Apply ( ZN >= 5.4.5 )


The file and directory are used to complete the transaction chain. Returns the return value of the last method.

Parameters

void
return Mixed

uses

echo Document::target('example.txt')
             ->create()
             ->write('Hello Body!')
             ->read()
             ->apply();
Hello Body!