Class AuthRule.DraftVersion
-
- All Implemented Interfaces:
public final class AuthRule.DraftVersion
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public final classAuthRule.DraftVersion.BuilderA builder for DraftVersion.
public final classAuthRule.DraftVersion.ParametersParameters for the Auth Rule
public final classAuthRule.DraftVersion.StateThe state of the draft version. Most rules are created synchronously and the state is immediately
SHADOWING. Rules backed by TypeScript code are compiled asynchronously — the state starts asPENDINGand transitions toSHADOWINGon success orERRORon failure.PENDING: Compilation of the rule is in progress (TypeScript rules only).SHADOWING: The draft version is ready and evaluating in shadow mode alongside the current active version. It can be promoted to the active version.ERROR: Compilation of the rule failed. Check theerrorfield for details.
-
Method Summary
Modifier and Type Method Description final Optional<String>error()An error message if the draft version failed compilation. final AuthRule.DraftVersion.Parametersparameters()Parameters for the Auth Rule final AuthRule.DraftVersion.Statestate()The state of the draft version. final Longversion()The version of the rule, this is incremented whenever the rule's parameters change. final JsonField<String>_error()Returns the raw JSON value of error. final JsonField<AuthRule.DraftVersion.Parameters>_parameters()Returns the raw JSON value of parameters. final JsonField<AuthRule.DraftVersion.State>_state()Returns the raw JSON value of state. final JsonField<Long>_version()Returns the raw JSON value of version. final Map<String, JsonValue>_additionalProperties()final AuthRule.DraftVersion.BuildertoBuilder()final AuthRule.DraftVersionvalidate()final BooleanisValid()Booleanequals(Object other)IntegerhashCode()StringtoString()final static AuthRule.DraftVersion.Builderbuilder()Returns a mutable builder for constructing an instance of DraftVersion. -
-
Method Detail
-
error
final Optional<String> error()
An error message if the draft version failed compilation. Populated when
stateisERROR,nullotherwise.
-
parameters
final AuthRule.DraftVersion.Parameters parameters()
Parameters for the Auth Rule
-
state
final AuthRule.DraftVersion.State state()
The state of the draft version. Most rules are created synchronously and the state is immediately
SHADOWING. Rules backed by TypeScript code are compiled asynchronously — the state starts asPENDINGand transitions toSHADOWINGon success orERRORon failure.PENDING: Compilation of the rule is in progress (TypeScript rules only).SHADOWING: The draft version is ready and evaluating in shadow mode alongside the current active version. It can be promoted to the active version.ERROR: Compilation of the rule failed. Check theerrorfield for details.
-
version
final Long version()
The version of the rule, this is incremented whenever the rule's parameters change.
-
_error
final JsonField<String> _error()
Returns the raw JSON value of error.
Unlike error, this method doesn't throw if the JSON field has an unexpected type.
-
_parameters
final JsonField<AuthRule.DraftVersion.Parameters> _parameters()
Returns the raw JSON value of parameters.
Unlike parameters, this method doesn't throw if the JSON field has an unexpected type.
-
_state
final JsonField<AuthRule.DraftVersion.State> _state()
Returns the raw JSON value of state.
Unlike state, this method doesn't throw if the JSON field has an unexpected type.
-
_version
final JsonField<Long> _version()
Returns the raw JSON value of version.
Unlike version, this method doesn't throw if the JSON field has an unexpected type.
-
_additionalProperties
final Map<String, JsonValue> _additionalProperties()
-
toBuilder
final AuthRule.DraftVersion.Builder toBuilder()
-
validate
final AuthRule.DraftVersion validate()
-
builder
final static AuthRule.DraftVersion.Builder builder()
Returns a mutable builder for constructing an instance of DraftVersion.
The following fields are required:
.error() .parameters() .state() .version()
-
-
-
-