zero.core.context

Class GlobalContext

public class GlobalContext
extends java.lang.Object

GlobalContext provides a central construct for applications to store and retrieve information. It allows users to read and write name-value pairs using keys that resemble a file system path (e.g., /request/headers/out). The first element in any global context key refers to the zone that stores it; each zone can have different rules about the lifetime, scope, and permissions of its data. In general, key-value relationships work very similar to those of java.util.Map classes, with non-primitive values (objects and collections) used frequently as a means of storing related data.

Constructor

GlobalContext()

Method Summary

static Context getContext()
static void setContext(Context context)
static boolean zcontains(ParsedURI parsedUri)
static boolean zcontains(String uri)
static boolean zdelete(String uri)
static boolean zdelete(String uri, boolean deleteChildren)
static String zdump(String uri)
static <T> T zget(ParsedURI parsedUri, T defaultValue)
static <T> T zget(String uri)
static <T> T zget(String uri, T defaultValue)
static List<String> zlist(String uriPrefix)
static List<String> zlist(String uriPrefix, boolean includePrefix)
static List<String> zlistAll(String uriPrefix)
static List<String> zlistAll(String uriPrefix, boolean includePrefix)
static <V> boolean zpost(ParsedURI uri, V value)
static <V> boolean zpost(String uri, V value)
static <V> boolean zput(ParsedURI uri, V value)
static <V> boolean zput(String uri, V value)
static Map<String,Boolean> zputs(String uriPrefix, Map<String,Object> payload)