Package org.onosproject.ui
Interface UiTopoLayoutService
-
public interface UiTopoLayoutService
Service for managingUiTopoLayout
instances. Those instances are used in conjunction with modeling the region-based topology views.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description boolean
addLayout(UiTopoLayout layout)
Adds a layout to the system or updates an existing one.java.util.Set<UiTopoLayout>
getChildren(UiTopoLayoutId layoutId)
Returns the set of the child layouts of the specified layout.UiTopoLayout
getLayout(RegionId regionId)
Returns the layout which has the backing region identified by the given region identifier.UiTopoLayout
getLayout(UiTopoLayoutId layoutId)
Returns the layout with the specified identifier.java.util.Set<UiTopoLayout>
getLayouts()
Returns the set of available layouts (not including the root layout).java.util.Set<UiTopoLayout>
getPeerLayouts(UiTopoLayoutId layoutId)
Returns the set of peer layouts of the specified layout.UiTopoLayout
getRootLayout()
Returns the top-level root layout, which always exists and cannot be removed or associated directly with a region.boolean
removeLayout(UiTopoLayout layout)
Removes a layout from the system.
-
-
-
Method Detail
-
getRootLayout
UiTopoLayout getRootLayout()
Returns the top-level root layout, which always exists and cannot be removed or associated directly with a region.- Returns:
- root topology layout
-
getLayouts
java.util.Set<UiTopoLayout> getLayouts()
Returns the set of available layouts (not including the root layout).- Returns:
- set of available layouts
-
addLayout
boolean addLayout(UiTopoLayout layout)
Adds a layout to the system or updates an existing one.- Parameters:
layout
- the layout to add or update- Returns:
- true if added; false if updated
-
getLayout
UiTopoLayout getLayout(UiTopoLayoutId layoutId)
Returns the layout with the specified identifier.- Parameters:
layoutId
- layout identifier- Returns:
- layout or null if no such layout is found
-
getLayout
UiTopoLayout getLayout(RegionId regionId)
Returns the layout which has the backing region identified by the given region identifier.- Parameters:
regionId
- region identifier- Returns:
- corresponding layout
-
getPeerLayouts
java.util.Set<UiTopoLayout> getPeerLayouts(UiTopoLayoutId layoutId)
Returns the set of peer layouts of the specified layout. That is, those layouts that share the same parent.- Parameters:
layoutId
- layout identifier- Returns:
- set of peer layouts; empty set if layout has no peers
-
getChildren
java.util.Set<UiTopoLayout> getChildren(UiTopoLayoutId layoutId)
Returns the set of the child layouts of the specified layout.- Parameters:
layoutId
- layout identifier- Returns:
- set of child layouts; empty set if layout has no children
-
removeLayout
boolean removeLayout(UiTopoLayout layout)
Removes a layout from the system.- Parameters:
layout
- the layout to remove- Returns:
- true if removed; false if no longer registered
-
-