Is the item to be used within the NavigationBar
Constructor for a new NavigationItem.
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.ux3.NavigationItem(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 |
---|---|---|---|
href | sap.ui.core.URI | Defines the link target URL. This property is optional and should only be set when required! The use of the href property is to not only allow users to navigate in-place by left-clicking NavigationItems, but also to allow right-click and then "open in new tab" or "open in new window". As long as href is not set, an empty window will open and stay blank. But when href is set, the new window/tab will load this URL and it is the application's responsibility to display what the user expects (e.g. the Shell, with the respective NavigationItem being selected). Visibility: public |
|
visible | boolean | true | Whether the NavigationItem is currently visible. When making NavigationItems invisible at runtime it is the application's responsibility to make sure it is not the currently selected one - or to select another one in this case. |
Default Aggregation: subItems
Name | Cardinality | Type | Description |
---|---|---|---|
subItems (default) | 0..n | sap.ui.ux3.NavigationItem |
Any NavigationItems on the next hierarchy level connected to this NavigationItem |
Method | Description |
---|---|
addSubItem |
Adds some subItem to the aggregation subItems. |
destroySubItems |
Destroys all the subItems in the aggregation subItems. |
sap.ui.ux3.NavigationItem.extend |
Creates a new subclass of class sap.ui.ux3.NavigationItem with name
|
getHref |
Gets current value of property href. Defines the link target URL. This property is optional and should only be set when required! The use of the href property is to not only allow users to navigate in-place by left-clicking NavigationItems, but also to allow right-click and then "open in new tab" or "open in new window". As long as href is not set, an empty window will open and stay blank. But when href is set, the new window/tab will load this URL and it is the application's responsibility to display what the user expects (e.g. the Shell, with the respective NavigationItem being selected). |
sap.ui.ux3.NavigationItem.getMetadata |
Returns a metadata object for class sap.ui.ux3.NavigationItem. |
getSubItems |
Gets content of aggregation subItems. Any NavigationItems on the next hierarchy level connected to this NavigationItem |
getVisible |
Gets current value of property visible. Whether the NavigationItem is currently visible. When making NavigationItems invisible at runtime it is the application's responsibility to make sure it is not the currently selected one - or to select another one in this case. Default value is |
indexOfSubItem |
Checks for the provided |
insertSubItem |
Inserts a subItem into the aggregation subItems. |
removeAllSubItems |
Removes all the controls from the aggregation subItems. Additionally, it unregisters them from the hosting UIArea. |
removeSubItem |
Removes a subItem from the aggregation subItems. |
setHref |
Sets a new value for property href. Defines the link target URL. This property is optional and should only be set when required! The use of the href property is to not only allow users to navigate in-place by left-clicking NavigationItems, but also to allow right-click and then "open in new tab" or "open in new window". As long as href is not set, an empty window will open and stay blank. But when href is set, the new window/tab will load this URL and it is the application's responsibility to display what the user expects (e.g. the Shell, with the respective NavigationItem being selected). When called with a value of |
setVisible |
Sets a new value for property visible. Whether the NavigationItem is currently visible. When making NavigationItems invisible at runtime it is the application's responsibility to make sure it is not the currently selected one - or to select another one in this case. When called with a value of Default value is |
Adds some subItem to the aggregation subItems.
Param | Type | DefaultValue | Description |
---|---|---|---|
oSubItem | sap.ui.ux3.NavigationItem |
The subItem to add; if empty, nothing is inserted |
Gets current value of property href.
Defines the link target URL. This property is optional and should only be set when required! The use of the href property is to not only allow users to navigate in-place by left-clicking NavigationItems, but also to allow right-click and then "open in new tab" or "open in new window". As long as href is not set, an empty window will open and stay blank. But when href is set, the new window/tab will load this URL and it is the application's responsibility to display what the user expects (e.g. the Shell, with the respective NavigationItem being selected).
Gets content of aggregation subItems.
Any NavigationItems on the next hierarchy level connected to this NavigationItem
Gets current value of property visible.
Whether the NavigationItem is currently visible. When making NavigationItems invisible at runtime it is the application's responsibility to make sure it is not the currently selected one - or to select another one in this case.
Default value is true
.
Checks for the provided sap.ui.ux3.NavigationItem
in the aggregation subItems. and returns its index if found or -1 otherwise.
Param | Type | DefaultValue | Description |
---|---|---|---|
oSubItem | sap.ui.ux3.NavigationItem |
The subItem whose index is looked for |
Inserts a subItem into the aggregation subItems.
Param | Type | DefaultValue | Description |
---|---|---|---|
oSubItem | sap.ui.ux3.NavigationItem |
The subItem to insert; if empty, nothing is inserted |
|
iIndex | int |
The |
Removes all the controls from the aggregation subItems.
Additionally, it unregisters them from the hosting UIArea.
Removes a subItem from the aggregation subItems.
Param | Type | DefaultValue | Description |
---|---|---|---|
vSubItem | int string sap.ui.ux3.NavigationItem |
The subItem to remove or its index or id |
Sets a new value for property href.
Defines the link target URL. This property is optional and should only be set when required! The use of the href property is to not only allow users to navigate in-place by left-clicking NavigationItems, but also to allow right-click and then "open in new tab" or "open in new window". As long as href is not set, an empty window will open and stay blank. But when href is set, the new window/tab will load this URL and it is the application's responsibility to display what the user expects (e.g. the Shell, with the respective NavigationItem being selected).
When called with a value of null
or undefined
, the default value of the property will be restored.
Param | Type | DefaultValue | Description |
---|---|---|---|
sHref | sap.ui.core.URI |
New value for property |
Sets a new value for property visible.
Whether the NavigationItem is currently visible. When making NavigationItems invisible at runtime it is the application's responsibility to make sure it is not the currently selected one - or to select another one in this case.
When called with a value of null
or undefined
, the default value of the property will be restored.
Default value is true
.
Param | Type | DefaultValue | Description |
---|---|---|---|
bVisible | boolean | true |
New value for property |