Export provides the possibility to generate a list of data in a specific format / type, e.g. CSV to use it in other programs / applications.
Constructor for a new Export.
Accepts an object literal mSettings
that defines initial property values, aggregated and associated objects as well as event handlers. See sap.ui.base.ManagedObject#constructor for a general description of the syntax of the settings object.
new sap.ui.core.util.Export(sId?, mSettings?)
Param | Type | Default Value | Description |
---|---|---|---|
sId? | string | id for the new control, generated automatically if no id is given |
|
mSettings? | object | initial settings for the new control |
Name | Type | Default Value | Description |
---|---|---|---|
blocked | boolean | false | Whether the control is currently in blocked state. Visibility: public |
busy | boolean | false | Whether the control is currently in busy state. Visibility: public |
busyIndicatorDelay | int | 1000 | The delay in milliseconds, after which the busy indicator will show up for this control. Visibility: public |
busyIndicatorSize | sap.ui.core.BusyIndicatorSize | Medium | The size of the BusyIndicator. For controls with a width smaller 3rem a |
fieldGroupIds | string[] | The IDs of a logical field group that this control belongs to. All fields in a logical field group should share the same For backward compatibility with older releases, field group IDs are syntactically not limited, but it is suggested to use only valid sap.ui.core.IDs. See #attachValidateFieldGroup or consult the Field Group documentation. |
|
visible | boolean | true | Whether the control should be visible on the screen. If set to false, a placeholder will be rendered to mark the location of the invisible control in the DOM of the current page. The placeholder will be hidden and have zero dimensions ( Also see InvisibleRenderer. Visibility: public |
Default Aggregation:
Name | Cardinality | Type | Description |
---|---|---|---|
_template | 0..1 | sap.ui.core.util.ExportRow |
Template row used for the export |
columns | 0..n | sap.ui.core.util.ExportColumn |
Columns for the Export. |
exportType | 0..1 | sap.ui.core.util.ExportType |
Type that generates the content. |
rows | 0..n | sap.ui.core.util.ExportRow |
Rows of the Export. |
Name | Cardinality | Type | Description |
---|---|---|---|
customData | 0..n | sap.ui.core.CustomData |
Custom Data, a data structure like a map containing arbitrary key value pairs. |
dependents | 0..n | sap.ui.core.Element |
Dependents are not rendered, but their databinding context and lifecycle are bound to the aggregating Element. |
dragDropConfig | 0..n | sap.ui.core.dnd.DragDropBase |
Defines the drag-and-drop configuration. Note: This configuration might be ignored due to control metadata restrictions. |
layoutData | 0..1 | sap.ui.core.LayoutData |
Defines the layout constraints for this control when it is used inside a Layout. LayoutData classes are typed classes and must match the embedding Layout. See VariantLayoutData for aggregating multiple alternative LayoutData instances to a single Element. |
tooltip | 0..1 | sap.ui.core.TooltipBase |
The tooltip that should be shown for this Element. In the most simple case, a tooltip is a string that will be rendered by the control and displayed by the browser when the mouse pointer hovers over the control's DOM. In this variant, Controls need to explicitly support this kind of tooltip as they have to render it, but most controls do. Exceptions will be documented for the corresponding controls (e.g. Alternatively, UI5 currently does not provide a recommended implementation of See the section Using Tooltips
|
Method | Description |
---|---|
addColumn |
Adds some column to the aggregation columns. |
addRow |
Adds some row to the aggregation rows. |
bindColumns |
Binds aggregation columns to model data. See ManagedObject.bindAggregation for a detailed description of the possible properties of |
bindRows |
Binds aggregation rows to model data. See ManagedObject.bindAggregation for a detailed description of the possible properties of |
destroyColumns |
Destroys all the columns in the aggregation columns. |
destroyExportType |
Destroys the exportType in the aggregation exportType. |
destroyRows |
Destroys all the rows in the aggregation rows. |
sap.ui.core.util.Export.extend |
Creates a new subclass of class sap.ui.core.util.Export with name
|
generate |
Generates the file content and returns a Promise with the instance as context (this). Please note: The return value was changed from jQuery Promises to standard ES6 Promises. jQuery specific Promise methods ('done', 'fail', 'always', 'pipe' and 'state') are still available but should not be used. Please use only the standard methods 'then' and 'catch'! |
getColumns |
Gets content of aggregation columns. Columns for the Export. |
getExportType |
Gets content of aggregation exportType. Type that generates the content. |
sap.ui.core.util.Export.getMetadata |
Returns a metadata object for class sap.ui.core.util.Export. |
getRows |
Gets content of aggregation rows. Rows of the Export. |
indexOfColumn |
Checks for the provided |
indexOfRow |
Checks for the provided |
insertColumn |
Inserts a column into the aggregation columns. |
insertRow |
Inserts a row into the aggregation rows. |
removeAllColumns |
Removes all the controls from the aggregation columns. Additionally, it unregisters them from the hosting UIArea. |
removeAllRows |
Removes all the controls from the aggregation rows. Additionally, it unregisters them from the hosting UIArea. |
removeColumn |
Removes a column from the aggregation columns. |
removeRow |
Removes a row from the aggregation rows. |
saveFile |
Generates the file content, triggers a download / save action and returns a Promise with the instance as context (this). For information about browser support, see Please note: The return value was changed from jQuery Promises to standard ES6 Promises. jQuery specific Promise methods ('done', 'fail', 'always', 'pipe' and 'state') are still available but should not be used. Please use only the standard methods 'then' and 'catch'! |
setExportType |
Sets the aggregated exportType. |
unbindColumns |
Unbinds aggregation columns from model data. |
unbindRows |
Unbinds aggregation rows from model data. |
Adds some column to the aggregation columns.
Param | Type | DefaultValue | Description |
---|---|---|---|
oColumn | sap.ui.core.util.ExportColumn |
The column to add; if empty, nothing is inserted |
Adds some row to the aggregation rows.
Param | Type | DefaultValue | Description |
---|---|---|---|
oRow | sap.ui.core.util.ExportRow |
The row to add; if empty, nothing is inserted |
Binds aggregation columns to model data.
See ManagedObject.bindAggregation for a detailed description of the possible properties of oBindingInfo
.
Param | Type | DefaultValue | Description |
---|---|---|---|
oBindingInfo | sap.ui.base.ManagedObject.AggregationBindingInfo |
The binding information |
Binds aggregation rows to model data.
See ManagedObject.bindAggregation for a detailed description of the possible properties of oBindingInfo
.
Param | Type | DefaultValue | Description |
---|---|---|---|
oBindingInfo | sap.ui.base.ManagedObject.AggregationBindingInfo |
The binding information |
Creates a new subclass of class sap.ui.core.util.Export with name sClassName
and enriches it with the information contained in oClassInfo
.
oClassInfo
might contain the same kind of information as described in sap.ui.core.Control.extend.
Param | Type | DefaultValue | Description |
---|---|---|---|
sClassName | string |
Name of the class being created |
|
oClassInfo | object |
Object literal with information about the class |
|
FNMetaImpl | function |
Constructor function for the metadata object; if not given, it defaults to the metadata implementation used by this class |
Generates the file content and returns a Promise with the instance as context (this).
The promise will be resolved with the generated content as a string.
Please note: The return value was changed from jQuery Promises to standard ES6 Promises. jQuery specific Promise methods ('done', 'fail', 'always', 'pipe' and 'state') are still available but should not be used. Please use only the standard methods 'then' and 'catch'!
Checks for the provided sap.ui.core.util.ExportColumn
in the aggregation columns. and returns its index if found or -1 otherwise.
Param | Type | DefaultValue | Description |
---|---|---|---|
oColumn | sap.ui.core.util.ExportColumn |
The column whose index is looked for |
Checks for the provided sap.ui.core.util.ExportRow
in the aggregation rows. and returns its index if found or -1 otherwise.
Param | Type | DefaultValue | Description |
---|---|---|---|
oRow | sap.ui.core.util.ExportRow |
The row whose index is looked for |
Inserts a column into the aggregation columns.
Param | Type | DefaultValue | Description |
---|---|---|---|
oColumn | sap.ui.core.util.ExportColumn |
The column to insert; if empty, nothing is inserted |
|
iIndex | int |
The |
Inserts a row into the aggregation rows.
Param | Type | DefaultValue | Description |
---|---|---|---|
oRow | sap.ui.core.util.ExportRow |
The row to insert; if empty, nothing is inserted |
|
iIndex | int |
The |
Removes all the controls from the aggregation columns.
Additionally, it unregisters them from the hosting UIArea.
Removes all the controls from the aggregation rows.
Additionally, it unregisters them from the hosting UIArea.
Removes a column from the aggregation columns.
Param | Type | DefaultValue | Description |
---|---|---|---|
vColumn | int string sap.ui.core.util.ExportColumn |
The column to remove or its index or id |
Removes a row from the aggregation rows.
Param | Type | DefaultValue | Description |
---|---|---|---|
vRow | int string sap.ui.core.util.ExportRow |
The row to remove or its index or id |
Generates the file content, triggers a download / save action and returns a Promise with the instance as context (this).
The promise will be resolved with the generated content as a string.
For information about browser support, see sap.ui.core.util.File.save
Please note: The return value was changed from jQuery Promises to standard ES6 Promises. jQuery specific Promise methods ('done', 'fail', 'always', 'pipe' and 'state') are still available but should not be used. Please use only the standard methods 'then' and 'catch'!
Param | Type | DefaultValue | Description |
---|---|---|---|
sFileName | string | "data" |
The file name |
Sets the aggregated exportType.
Param | Type | DefaultValue | Description |
---|---|---|---|
oExportType | sap.ui.core.util.ExportType |
The exportType to set |