Class AbstractPathService
java.lang.Object
org.jboss.as.controller.services.path.AbstractPathService
- All Implemented Interfaces:
org.jboss.msc.Service,org.jboss.msc.service.Service<String>,org.jboss.msc.value.Value<String>
- Direct Known Subclasses:
AbsolutePathService,RelativePathService
public abstract class AbstractPathService
extends Object
implements org.jboss.msc.service.Service<String>
Abstract superclass for services that return a path.
- Author:
- Brian Stansberry, Richard Opalka
-
Field Summary
Fields inherited from interface org.jboss.msc.service.Service
NULL -
Method Summary
Modifier and TypeMethodDescriptiongetValue()static booleanChecks whether the given path looks like an absolute Unix or Windows filesystem pathname without regard for what the filesystem is underlying the Java Virtual Machine.static org.jboss.msc.service.ServiceNamepathNameOf(String pathName) protected abstract Stringvoidstart(org.jboss.msc.service.StartContext context) voidstop(org.jboss.msc.service.StopContext context)
-
Method Details
-
pathNameOf
-
isAbsoluteUnixOrWindowsPath
Checks whether the given path looks like an absolute Unix or Windows filesystem pathname without regard for what the filesystem is underlying the Java Virtual Machine. A UNIX pathname is absolute if its prefix is"/". A Microsoft Windows pathname is absolute if its prefix is a drive specifier followed by"\\", or if its prefix is"\\\\".This method differs from simply creating a new
Fileand callingFile.isAbsolute()in that its results do not change depending on what the filesystem underlying the Java Virtual Machine is.- Parameters:
path- the path- Returns:
trueifpathlooks like an absolute Unix or Windows pathname
-
start
public void start(org.jboss.msc.service.StartContext context) - Specified by:
startin interfaceorg.jboss.msc.Service
-
stop
public void stop(org.jboss.msc.service.StopContext context) - Specified by:
stopin interfaceorg.jboss.msc.Service
-
getValue
- Specified by:
getValuein interfaceorg.jboss.msc.value.Value<String>- Throws:
IllegalStateException
-
resolvePath
-