Property | Type | Description | |
---|---|---|---|
$globalFunctionsHelper | Helper to work with global functions | ||
$isStreamOpened | Indicates whether the stream is currently open | ||
$options | Reader's customized options |
Method | Description | |
---|---|---|
close ( ) : void | Closes the reader, preventing any additional reading | |
getSheetIterator ( ) : Iterator | Returns an iterator to iterate over sheets. | |
open ( string $filePath ) : void | Prepares the reader to read the given file. It also makes sure that the file exists and is readable. | |
setGlobalFunctionsHelper ( Box\Spout\Common\Helper\GlobalFunctionsHelper $globalFunctionsHelper ) : |
||
setShouldFormatDates ( boolean $shouldFormatDates ) : |
Sets whether date/time values should be returned as PHP objects or be formatted as strings. | |
setShouldPreserveEmptyRows ( boolean $shouldPreserveEmptyRows ) : |
Sets whether empty rows should be returned or skipped. |
Method | Description | |
---|---|---|
closeReader ( ) : |
Closes the reader. To be used after reading the file. | |
doesSupportStreamWrapper ( ) : boolean | Returns whether stream wrappers are supported | |
getConcreteSheetIterator ( ) : Iterator | Returns an iterator to iterate over sheets. | |
getFileRealPath ( string $filePath ) : string | Returns the real path of the given path. | |
getOptions ( ) : |
Returns the reader's current options | |
getStreamWrapperScheme ( string $filePath ) : string | null | Returns the scheme of the custom stream wrapper, if the path indicates a stream wrapper is used. | |
isPhpStream ( string $filePath ) : boolean | Checks if a path is a PHP stream (like php://output, php://memory, . | |
isStreamWrapper ( string $filePath ) : boolean | Checks if the given path is an unsupported stream wrapper (like local path, php://temp, mystream://foo/bar. | |
isSupportedStreamWrapper ( string $filePath ) : boolean | Checks if the given path is an supported stream wrapper (like php://temp, mystream://foo/bar. | |
openReader ( string $filePath ) : void | Opens the file at the given file path to make it ready to be read |
abstract protected closeReader ( ) : |
||
return |
abstract protected doesSupportStreamWrapper ( ) : boolean | ||
return | boolean |
abstract protected getConcreteSheetIterator ( ) : Iterator | ||
return | Iterator | To iterate over sheets |
protected getFileRealPath ( string $filePath ) : string | ||
$filePath | string | |
return | string |
abstract protected getOptions ( ) : |
||
return |
public getSheetIterator ( ) : Iterator | ||
return | Iterator | To iterate over sheets |
protected isPhpStream ( string $filePath ) : boolean | ||
$filePath | string | Path of the file to be read |
return | boolean | Whether the given path maps to a PHP stream |
protected isStreamWrapper ( string $filePath ) : boolean | ||
$filePath | string | Path of the file to be read |
return | boolean | Whether the given path is an unsupported stream wrapper |
protected isSupportedStreamWrapper ( string $filePath ) : boolean | ||
$filePath | string | Path of the file to be read |
return | boolean | Whether the given path is an supported stream wrapper |
abstract protected openReader ( string $filePath ) : void | ||
$filePath | string | Path of the file to be read |
return | void |
public setGlobalFunctionsHelper ( Box\Spout\Common\Helper\GlobalFunctionsHelper $globalFunctionsHelper ) : |
||
$globalFunctionsHelper | Box\Spout\Common\Helper\GlobalFunctionsHelper | |
return |
public setShouldFormatDates ( boolean $shouldFormatDates ) : |
||
$shouldFormatDates | boolean | |
return |
public setShouldPreserveEmptyRows ( boolean $shouldPreserveEmptyRows ) : |
||
$shouldPreserveEmptyRows | boolean | |
return |
protected $globalFunctionsHelper |
protected $isStreamOpened |