Table of Contents |
---|
Overview
There are a number of Angular-based services that the ONOS GUI comes with ready made. All of our services are actually factories. Below you will find short summaries of what each service provides and links to pages with more information.
Most of the ONOS Web UI framework code is implemented as Angular services (factories, in fact). This page provides a brief summary of these factories, with links to pages giving more detail.
The source code can be found in All of these services are in the directory web/gui/src/main/webapp/app/fw/.
Layer
The module holding these services is onosLayer
and is defined in layer/layer.js
.
Service | Description | ||
---|---|---|---|
FlashService | Allows user application code to flash transient messages on the screen. | ||
LoadingService | Provides the ONOS-branded "Loading..." animation. | ||
PanelService | Provides an API to create and destroy "fly-in" panels. | ||
DialogService | Builds on the panel service to create a dialog panel. | ||
QuickHelpService | Renders the Quick Help | QuickHelpService | Allows user to display a quick help panel. |
VeilService | Manages an overlay masking layer that appears when the websocket web-socket connection fails. |
Mast
The module holding these services is onosMast
and is defined in mast/mast.js
.
Service | Description |
---|---|
MastService | Returns the height of the mast in pixelsProvides functions relating to the masthead. |
Nav
The module holding these services is onosNav
and is defined in nav/nav.js
.
Service | Description |
---|---|
NavService | Manages the menu navigation pane. |
Remote
The module holding these services is onosRemote
and is defined in remote/remote.js
.
Service | Description |
---|---|
RestService | Abstracts rest calls using the $http service. |
UrlFnService | Creates URL strings for REST or Websocket web-socket calls. |
WebSocketService | Handles Websocket events (bind, unbind, listeners). |
WsEventService | Send events with the Websocket (used by other services). |
WSock | Web-socket wrapper to facilitate unit-testing with mock web-sockets. |
SVG
The module holding these services is onosSvg
and is defined in svg/svg.js
.
Service | Description |
---|---|
GeoDataService | Fetches and caches TopoJSON data, provides a way of providing an API for creating a path generator for that data. |
GlyphService | Add, load, and register SVG symbols (glyphs). |
IconService | Add, load, and register SVG icons via a service (abstraction of GlyphService) or a directive. |
MapService | Loads graphical maps into the SVG layer. |
SvgUtilService | General SVG utility functions. |
ZoomService | Creates a "zoomer" to manage zoom functions in on an SVG mapslayer. |
Util
The module holding these services is onosUtil
and is defined in util/util.js
.
Service | Description |
---|---|
FnService | Provides general purpose functions that are useful throughout the application. |
KeyService | Bind and enable keys to certain functionsProvides key-bindings to function callbacks. |
PrefsService | Stores Persists user settings in the browser's cookies. |
Encapsulated randomness. | |
ThemeService | Manages theme add, remove, and toggleUI themes (light and dark). |
Widget
The module holding these services is onosWidget
and is defined in widget/widget.js
.
Service | Description | ||
---|---|---|---|
ButtonService | Provides an API to create buttons, toggles, and radio button sets. | ||
Table Directives | Defines Angular directives for tabular views | TableService | Allows user to reset sort icons created by the directives written for tables. |
TableBuilderService | Builds Provides an API to create a generic table view client model. | ||
ToolbarService | Provides an API to create a toolbar. | ||
TooltipService | Provides an API and a directive to install tooltips. |