Package de.scravy.bedrock
Class Context
java.lang.Object
de.scravy.bedrock.Context
public class Context extends Object
-
Constructor Summary
Constructors Constructor Description Context() -
Method Summary
Modifier and Type Method Description static Objectget(String id)static <T> Tget(String id, Class<T> clazz)static ContextgetInstance()static <T> Optional<T>getOptionally(String id, Class<T> clazz)static voidwithContext(ArrayMap<String,Object> mappings, ThrowingRunnable f)
-
Constructor Details
-
Context
public Context()
-
-
Method Details
-
get
-
getOptionally
-
get
@Nonnull public static <T> T get(@Nonnull String id, @Nonnull Class<T> clazz) throws IllegalStateException- Throws:
IllegalStateException
-
withContext
-
getInstance
- Throws:
IllegalStateException
-