Package com.sodius.oslc.server.process
Class GlobalConfigurationResolver
- java.lang.Object
-
- com.sodius.oslc.server.process.GlobalConfigurationResolver
-
public abstract class GlobalConfigurationResolver extends Object
Allows to resolveGlobal Configurations
used byapplication artifacts
and to determine theGlobal Configuration awareness
of a container.- Since:
- 3.7.0
-
-
Constructor Summary
Constructors Constructor Description GlobalConfigurationResolver()
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description GlobalConfigurationAware
getGlobalConfigurationAware(ApplicationContainer container, URI domain)
Determines theGlobal Configuration awareness
of an application container.static GlobalConfigurationResolver
getInstance()
Gets the GC resolver implementation.abstract Optional<ConfigurationTrace>
resolve(ApplicationArtifact artifact, ApplicationContainer container, LinkingType linkingType)
Resolves (if any) the (traced) Global Configuration used (URI and title), by an application artifact, for linking.static void
setInstance(GlobalConfigurationResolver resolver)
Sets the application GC resolver implementation.
-
-
-
Method Detail
-
getInstance
public static GlobalConfigurationResolver getInstance()
Gets the GC resolver implementation.- Returns:
- the application GC resolver implementation if
specified
; otherwise, the default implementation which always resolves an emptyOptional
.
-
setInstance
public static void setInstance(GlobalConfigurationResolver resolver)
Sets the application GC resolver implementation. Applications not using a GC are not required to call this method, an implementation, which always resolves an emptyOptional
, is set by default.- Parameters:
resolver
- application GC resolver.
-
resolve
public abstract Optional<ConfigurationTrace> resolve(ApplicationArtifact artifact, ApplicationContainer container, LinkingType linkingType)
Resolves (if any) the (traced) Global Configuration used (URI and title), by an application artifact, for linking.- Parameters:
artifact
- the application artifact.container
- the application artifact container.linkingType
- the linking type.- Returns:
- an empty
Optional
if no Global Configuration is being used; the traced reference otherwise. - Throws:
OslcWebApplicationException
- if the Global Configuration cannot be determined.- Since:
- 3.8.0
-
getGlobalConfigurationAware
public GlobalConfigurationAware getGlobalConfigurationAware(ApplicationContainer container, URI domain)
Determines theGlobal Configuration awareness
of an application container.- Parameters:
container
- the application artifact container.domain
- the domain URI of the application artifact container.- Returns:
- the Global Configuration awareness of the
container
. - Since:
- 3.8.0
-
-