Property | Type | Description | |
---|---|---|---|
$storage | Horde_Data_Storage | Storage object. |
Property | Type | Description | |
---|---|---|---|
$_browser | Horde_Browser | Browser object. | |
$_cleanupCallback | callback | Cleanup callback function. | |
$_contentType | string | MIME content type. | |
$_extension | string | File extension. | |
$_http | Horde_Http_Client | HTTP client object. | |
$_vars | Horde_Variables | Variables object. | |
$_warnings | array | A list of warnings raised during the last operation. |
Method | Description | |
---|---|---|
__construct ( Horde_Data_Storage $storage, array $params = [] ) | Constructor. | |
cleanup ( ) : mixed | Removes any uploaded and moved files. | |
exportData ( $data, $method = 'REQUEST' ) | Stub to return exported data. | |
exportFile ( $filename, $data ) | Stub to export data to a file. | |
getContentType ( ) : string | Returns the content type. | |
getFilename ( string $basename ) : string | Returns the full filename including the basename and extension. | |
getNewline ( ) : string | Tries to determine the expected newline character based on the platform information passed by the browser's agent header. | |
importData ( $text ) | Stub to import passed data. | |
importFile ( $filename, $header = false ) | Imports a file. | |
importUrl ( $url, $header = false ) | Imports a URL. | |
nextStep ( integer $action, array $param = [] ) : mixed | Takes all necessary actions for the given import step, parameters and form values and returns the next necessary step. | |
warnings ( ) : array | Returns a list of warnings that have been raised during the last operation. |
Method | Description | |
---|---|---|
_mapDate ( string $date, string $type, array $params, integer $key ) : string | Maps a date/time string to an associative array. |
public __construct ( Horde_Data_Storage $storage, array $params = [] ) | ||
$storage | Horde_Data_Storage | |
$params | array | Optional parameters: - browser: (Horde_Browser) A browser object. - http: (Horde_Http_Client) A HTTP client object. - cleanup: (callback) A callback to call at cleanup time. - vars: (Horde_Variables) Form data. |
protected _mapDate ( string $date, string $type, array $params, integer $key ) : string | ||
$date | string | The date. |
$type | string | One of 'date', 'time' or 'datetime'. |
$params | array | Two-dimensional array with additional information about the formatting. Possible keys are: - delimiter: The character that seperates the different date/time parts. - format: If 'ampm' and $date contains a time we assume that it is in AM/PM format. - order: If $type is 'datetime' the order of the day and time parts: -1 (timestamp), 0 (day/time), 1 (time/day). |
$key | integer | The key to use for $params. |
return | string | The date or time in ISO format. |
abstract public exportData ( $data, $method = 'REQUEST' ) |
abstract public exportFile ( $filename, $data ) |
public getContentType ( ) : string | ||
return | string | The content type. |
public getFilename ( string $basename ) : string | ||
$basename | string | Basename for the file. |
return | string | The file name. |
public getNewline ( ) : string | ||
return | string | The guessed expected newline characters, either \n, \r or \r\n. |
public nextStep ( integer $action, array $param = [] ) : mixed | ||
$action | integer | The current step. One of the IMPORT_* constants. |
$param | array | An associative array containing needed parameters for the current step. |
return | mixed | Either the next step as an integer constant or imported data set after the final step. |
protected callback $_cleanupCallback | ||
return | callback |
protected Horde_Http_Client $_http | ||
return | Horde_Http_Client |
protected array $_warnings | ||
return | array |