cloud.prefab.client.LiveValuesConfigClient Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of client Show documentation
Show all versions of client Show documentation
API Client for https://prefab.cloud: rate limits, feature flags and semaphores as a service
package cloud.prefab.client;
import cloud.prefab.client.value.Value;
import cloud.prefab.context.ContextStore;
import cloud.prefab.context.PrefabContext;
import java.time.Duration;
import java.util.List;
public interface LiveValuesConfigClient {
/**
* Evaluates a configuration based on context from the ContextStore
* ie set via {@link ContextStore#addContext(PrefabContext) addContext}
* @param key name of the config to evaluate
* @return a value that will be evaluated at runtime based on the context from the current scope
*/
Value liveString(String key);
/**
* Evaluates a configuration based on context from the ContextStore
* ie set via {@link ContextStore#addContext(PrefabContext) addContext}
* @param key name of the config to evaluate
* @return a value that will be evaluated at runtime based on the context from the current scope
*/
Value> liveStringList(String key);
/**
* Evaluates a configuration based on context from the ContextStore
* ie set via {@link ContextStore#addContext(PrefabContext) addContext}
* @param key name of the config to evaluate
* @return a value that will be evaluated at runtime based on the context from the current scope
*/
Value liveBoolean(String key);
/**
* Evaluates a configuration based on context from the ContextStore
* ie set via {@link ContextStore#addContext(PrefabContext) addContext}
* @param key name of the config to evaluate
* @return a value that will be evaluated at runtime based on the context from the current scope
*/
Value liveLong(String key);
/**
* Evaluates a configuration based on context from the ContextStore
* ie set via {@link ContextStore#addContext(PrefabContext) addContext}
* @param key name of the config to evaluate
* @return a value that will be evaluated at runtime based on the context from the current scope
*/
Value liveDouble(String key);
/**
* Evaluates a configuration based on context from the ContextStore
* ie set via {@link ContextStore#addContext(PrefabContext) addContext}
* @param key name of the config to evaluate
* @return a Duration value that will be evaluated at runtime based on the context from the current scope
*/
Value liveDuration(String key);
}