API / geotoolkit / seismic / data / BrowserLocalFile / LocalFile
data.BrowserLocalFile.LocalFile
Creates wrapper class for a file reader.
Constructors
Constructors
• new LocalFile(file)
| Name | Type | Description |
|---|---|---|
file | string | File | the local file for e.g SEG-Y file. |
Methods
▸ getFileName(): string
Returns file name
string
file name
▸ getFileSize(): number
Return file size
number
▸ getLastModified(): number
Returns the last modified date of the file as the number of milliseconds since the Unix epoch (January 1, 1970 at midnight). Files without a known last modified date return the current date.
number
▸ readBinarySection(callback, from, to): void
Returns binary raw data
| Name | Type | Description |
|---|---|---|
callback | (res: string | ArrayBuffer) => void | this is the function called when data is ready |
from | number | offset in bytes |
to | number | offset in bytes |
void
▸ Static isSupported(): boolean
Return true if local file is supported
boolean