Package org.kinotic.continuum.grind.api
Class ContextUtils
- java.lang.Object
-
- org.kinotic.continuum.grind.api.ContextUtils
-
public class ContextUtils extends java.lang.ObjectCreated by Navid Mitchell on 7/7/20
-
-
Constructor Summary
Constructors Constructor Description ContextUtils()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static org.springframework.core.env.MapPropertySourcegetGrindPropertySource(org.springframework.context.support.GenericApplicationContext applicationContext)Returns theMapPropertySourceused internally by "Grind" to store property values duringTaskexecutionstatic <T> TgetProperty(java.lang.String propertyName, org.springframework.context.support.GenericApplicationContext applicationContext)Gets a property from the given active context.
-
-
-
Method Detail
-
getProperty
public static <T> T getProperty(java.lang.String propertyName, org.springframework.context.support.GenericApplicationContext applicationContext)Gets a property from the given active context.- Type Parameters:
T- type of the property expected- Parameters:
propertyName- the name of the property to retrieve- Returns:
- the property or null if not value is found for the given name
-
getGrindPropertySource
public static org.springframework.core.env.MapPropertySource getGrindPropertySource(org.springframework.context.support.GenericApplicationContext applicationContext)
Returns theMapPropertySourceused internally by "Grind" to store property values duringTaskexecution- Parameters:
applicationContext- to get theMapPropertySourcefrom- Returns:
- the
MapPropertySource
-
-