Interface PathManager
-
- All Known Implementing Classes:
PathManagerService
public interface PathManagerThe client interface for thePathManagerService- Author:
- Kabir Khan
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static interfacePathManager.CallbackA callback, seeregisterCallback(String, Callback, Event...)static classPathManager.EventAn event triggered when changes are made to a path entrystatic interfacePathManager.PathEventContextstatic classPathManager.ReloadServerCallbackFactory for aPathManager.Callbackthat always callsPathManager.PathEventContext.reloadRequired()from itsPathManager.Callback.pathModelEvent(PathEventContext, String)method.
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description PathEntrygetPathEntry(String name)Gets a path entryPathManager.Callback.HandleregisterCallback(String name, PathManager.Callback callback, PathManager.Event... events)Registers a callback for when a path is added/changed/removedStringresolveRelativePathEntry(String path, String relativeTo)Resolves a relative path
-
-
-
Method Detail
-
resolveRelativePathEntry
String resolveRelativePathEntry(String path, String relativeTo)
Resolves a relative path- Parameters:
path- an absolute path ifrelativeToisnull, the relative path torelativeTootherwiserelativeTo- the name of the path this is relative to, may benull- Returns:
- the resolved path
- Throws:
IllegalStateException- if there is no path registered underrelativeTo
-
getPathEntry
PathEntry getPathEntry(String name)
Gets a path entry- Parameters:
name- the name of the path- Returns:
- the path
- Throws:
IllegalStateException- if there is no path registered underpath
-
registerCallback
PathManager.Callback.Handle registerCallback(String name, PathManager.Callback callback, PathManager.Event... events)
Registers a callback for when a path is added/changed/removed- Parameters:
name- the name of the pathcallback- the callback instance that will be called when one of the events occurevents- the events we are interested in- Returns:
- a handle to unregister the callback
-
-