Interface ZooInspectorManager
- All Superinterfaces:
ZooInspectorNodeManager
,ZooInspectorNodeTreeManager
,ZooInspectorReadOnlyManager
- All Known Implementing Classes:
ZooInspectorManagerImpl
A Manager for all interactions between the application and the Zookeeper
instance
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addWatchers
(Collection<String> selectedNodes, NodeListener nodeListener) boolean
connect
(Properties connectionProps) boolean
loadNodeViewersFile
(File selectedFile) void
removeWatchers
(Collection<String> selectedNodes) void
void
saveNodeViewersFile
(File selectedFile, List<String> nodeViewersClassNames) void
setDefaultNodeViewerConfiguration
(List<String> nodeViewersClassNames) void
setLastConnectionProps
(Properties connectionProps) Methods inherited from interface org.apache.zookeeper.inspector.manager.ZooInspectorNodeManager
setData
Methods inherited from interface org.apache.zookeeper.inspector.manager.ZooInspectorNodeTreeManager
createNode, deleteNode
Methods inherited from interface org.apache.zookeeper.inspector.manager.ZooInspectorReadOnlyManager
getACLs, getChildren, getData, getNodeMeta, getNumChildren
-
Method Details
-
connect
- Parameters:
connectionProps
-- Returns:
- true if successfully connected
-
disconnect
boolean disconnect()- Returns:
- true if successfully disconnected
-
getConnectionPropertiesTemplate
- Returns:
- a
Pair
containing the following:- a
Map
of property keys to list of possible values. If the list size is 1 the value is taken to be the default value for aJTextField
. If the list size is greater than 1, the values are taken to be the possible options to show in aJComboBox
with the first selected as default. - a
Map
of property keys to the label to show on the UI
- a
-
addWatchers
- Parameters:
selectedNodes
- - the nodes to add the watcher tonodeListener
- - the node listener for this watcher
-
removeWatchers
- Parameters:
selectedNodes
- - the nodes to remove the watchers from
-
loadNodeViewersFile
- Parameters:
selectedFile
- - the file to load which contains the node viewers configuration- Returns:
- nodeViewers - the class names of the node viewers from the configuration
- Throws:
IOException
- - if the configuration file cannot be loaded
-
saveNodeViewersFile
- Parameters:
selectedFile
- - the file to save the configuration tonodeViewersClassNames
- - the class names of the node viewers- Throws:
IOException
- - if the configuration file cannot be saved
-
setDefaultNodeViewerConfiguration
- Parameters:
nodeViewersClassNames
- - the class names of the node viewers- Throws:
IOException
- - if the default configuration file cannot be loaded
-
getDefaultNodeViewerConfiguration
- Returns:
- nodeViewers - the class names of the node viewers from the configuration
- Throws:
IOException
- - if the default configuration file cannot be loaded
-
setLastConnectionProps
- Parameters:
connectionProps
- - the connection properties last used to connect to the zookeeeper instance
-
getLastConnectionProps
Properties getLastConnectionProps()- Returns:
- last connection Properties - the connection properties last used to connect to the zookeeeper instance
-
saveDefaultConnectionFile
- Parameters:
props
- - the properties to use as the default connection settings- Throws:
IOException
- - if the default configuration file cannot be saved
-