| Modifier and Type | Field and Description |
|---|---|
static GRN |
GLOBAL_USER_GRN |
| Modifier and Type | Method and Description |
|---|---|
static GRNRegistry |
createEmpty()
Returns an empty registry.
|
static GRNRegistry |
createWithBuiltinTypes()
Returns a registry that has been initialized with the builtin Graylog GRN types.
|
static GRNRegistry |
createWithTypes(Collection<GRNType> types)
Returns a registry that has been initialized with the given GRN types.
|
boolean |
isUser(GRN grn) |
GRN |
newGRN(GRNType type,
String entity)
Returns the
GRN for the given type and entity. |
GRN |
newGRN(String type,
String entity)
Returns the
GRN for the given type and entity. |
GRN.Builder |
newGRNBuilder(GRNType type)
Returns a new
GRN.Builder for the given type string. |
GRN.Builder |
newGRNBuilder(String type)
Returns a new
GRN.Builder for the given type string. |
GRN |
ofEventDefinition(EventDefinition eventDefinition) |
GRN |
ofUser(User user) |
GRN |
parse(String grnString)
Parses the given GRN string and returns a
GRN. |
void |
registerType(GRNType type)
Registers the given GRN type.
|
public static final GRN GLOBAL_USER_GRN
public static GRNRegistry createEmpty()
public static GRNRegistry createWithBuiltinTypes()
public static GRNRegistry createWithTypes(Collection<GRNType> types)
types - the GRN types to initialize the registry withpublic GRN parse(String grnString)
GRN.grnString - the GRN string to parseIllegalArgumentException - when given GRN string is invalidpublic GRN newGRN(String type, String entity)
GRN for the given type and entity.type - the GRN type stringentity - the entity stringIllegalArgumentException - when given type doesn't exist or any arguments are null or emptypublic GRN newGRN(GRNType type, String entity)
GRN for the given type and entity.type - the GRN type stringentity - the entity stringIllegalArgumentException - when given type doesn't exist or any arguments are null or emptypublic GRN ofEventDefinition(EventDefinition eventDefinition)
public boolean isUser(GRN grn)
public GRN.Builder newGRNBuilder(String type)
GRN.Builder for the given type string.type - the GRN type stringIllegalArgumentException - when given type doesn't existpublic GRN.Builder newGRNBuilder(GRNType type)
GRN.Builder for the given type string.type - the GRN type stringIllegalArgumentException - when given type doesn't existpublic void registerType(GRNType type)
type - the typt to registerIllegalStateException - when given type is already registeredCopyright © 2012–2021 Graylog, Inc.. All rights reserved.