public final class Env
extends java.lang.Object
Mark a module should only be loaded in certain environment
Modifier and Type | Class and Description |
---|---|
static interface |
Env.Group
Deprecated.
|
static interface |
Env.Mode
Used to mark a dependency injector module that should be load only in specified mode
|
static class |
Env.PID |
static interface |
Env.Profile
Deprecated.
|
static interface |
Env.RequireGroup
Used to mark a dependency injector module that should be load only in specified node group
|
static interface |
Env.RequireMode
Used to mark a dependency injector module that should be load only in specified mode
|
static interface |
Env.RequireProfile
Used to mark a dependency injector module that should be load only in specified profile.
|
Modifier and Type | Method and Description |
---|---|
static boolean |
groupMatches(java.lang.String group) |
static boolean |
groupMatches(java.lang.String group,
boolean unless) |
static boolean |
isEnvAnnotation(java.lang.Class<? extends java.lang.annotation.Annotation> type) |
static boolean |
matches(java.lang.reflect.AnnotatedElement annotatedElement)
Determine if an
AnnotatedElement has environment annotations and if it has then check if all environment annotations matches the current executing environment |
static boolean |
matches(Env.Group groupTag)
Deprecated.
|
static boolean |
matches(Env.Mode modeTag)
Deprecated.
|
static boolean |
matches(Env.Profile profileTag)
Deprecated.
|
static boolean |
matches(Env.RequireGroup groupTag) |
static boolean |
matches(Env.RequireMode modeTag) |
static boolean |
matches(Env.RequireProfile profileTag) |
static boolean |
modeMatches(Act.Mode mode) |
static boolean |
modeMatches(Act.Mode mode,
boolean unless) |
static boolean |
profileMatches(java.lang.String profile) |
static boolean |
profileMatches(java.lang.String profile,
boolean unless) |
public static boolean matches(Env.RequireMode modeTag)
@Deprecated public static boolean matches(Env.Mode modeTag)
This method is deprecated. Please use matches(RequireMode)
instead
public static boolean modeMatches(Act.Mode mode)
public static boolean modeMatches(Act.Mode mode, boolean unless)
public static boolean matches(Env.RequireProfile profileTag)
@Deprecated public static boolean matches(Env.Profile profileTag)
This method is deprecated. Please use matches(RequireProfile)
instead
public static boolean profileMatches(java.lang.String profile)
public static boolean profileMatches(java.lang.String profile, boolean unless)
public static boolean matches(Env.RequireGroup groupTag)
@Deprecated public static boolean matches(Env.Group groupTag)
This method is deprecated. Please use matches(RequireGroup)
instead
public static boolean groupMatches(java.lang.String group)
public static boolean groupMatches(java.lang.String group, boolean unless)
public static boolean isEnvAnnotation(java.lang.Class<? extends java.lang.annotation.Annotation> type)
public static boolean matches(java.lang.reflect.AnnotatedElement annotatedElement)
Determine if an AnnotatedElement
has environment annotations and if it has then check if all environment annotations matches the current executing environment
annotatedElement
- an annotated elementtrue
if the element does not have environment annotations or all environment annotations matchesCopyright © 2014–2017 ActFramework. All rights reserved.