Package io.micronaut.context.env
Interface ActiveEnvironment
-
public interface ActiveEnvironment
An environment that is active for the current execution of the application.- Since:
- 1.2.0
-
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Modifier and Type Method Description java.lang.String
getName()
int
getPriority()
A 0 based index representing the priority of the environment relative to other active environments.static ActiveEnvironment
of(java.lang.String name, int priority)
Creates a new active environment for the given arguments.
-
-
-
Method Detail
-
getName
java.lang.String getName()
- Returns:
- The name of the environment
-
getPriority
int getPriority()
A 0 based index representing the priority of the environment relative to other active environments.- Returns:
- The priority
-
of
static ActiveEnvironment of(java.lang.String name, int priority)
Creates a new active environment for the given arguments.- Parameters:
name
- The environment namepriority
- The priority- Returns:
- The active environment
-
-