Blocks
FinalYes
BlockLifecycle::filled() fires per full block so remote filesystems upload it.
Methods
- __construct() : mixed
- all() : array<string|int, Block>
- append() : void
- block() : Block
- count() : int
- done() : void
- fromResource() : void
- size() : int
Methods
__construct()
public
__construct(int<1, max> $blockSize[, BlockFactory $blockFactory = new NativeLocalFileBlocksFactory() ][, BlockLifecycle $blockLifecycle = new BlockVoidLifecycle() ]) : mixed
Parameters
- $blockSize : int<1, max>
-
block size in bytes
- $blockFactory : BlockFactory = new NativeLocalFileBlocksFactory()
- $blockLifecycle : BlockLifecycle = new BlockVoidLifecycle()
all()
public
all() : array<string|int, Block>
Return values
array<string|int, Block>append()
public
append(string $data) : void
Parameters
- $data : string
block()
public
block() : Block
Return values
Block —- current block that might not be filled yet
count()
public
count() : int
Return values
intdone()
public
done() : void
fromResource()
public
fromResource(resource $resource) : void
Parameters
- $resource : resource
size()
public
size() : int