| Package | Description |
|---|---|
| net.morimekta.providence | |
| net.morimekta.providence.descriptor | |
| net.morimekta.providence.util |
| Modifier and Type | Class and Description |
|---|---|
static class |
PApplicationException._Field |
| Modifier and Type | Method and Description |
|---|---|
default <T,F extends PField<Message>> |
PMessageOrBuilder.get(F field) |
default <T,F extends PField<Message>> |
PMessage.get(F field) |
default <F extends PField<Message>> |
PMessageOrBuilder.has(F field) |
default <F extends PField<Message>> |
PMessage.has(F field) |
| Modifier and Type | Method and Description |
|---|---|
PField<Union> |
PUnion.unionField()
The user should be able to assume that this value never is null.
|
| Modifier and Type | Method and Description |
|---|---|
Collection<PField<Message>> |
PMessageBuilder.modifiedFields()
Get a Collection of F with fields Modified since creation of the builder.
|
Collection<PField<Message>> |
PMessageBuilder.presentFields()
Get a Collection of F with fields set on the builder.
|
| Modifier and Type | Method and Description |
|---|---|
PMessageBuilder<Message> |
PMessageBuilder.addTo(PField<Message> field,
Object value)
Checks if a specific field is set on the builder.
|
PMessageBuilder<Message> |
PMessageBuilder.clear(PField<Message> field)
Clear the provided field value.
|
boolean |
PMessageBuilder.isModified(PField<Message> field)
Checks if a specific field is modified on the builder.
|
boolean |
PMessageBuilder.isSet(PField<Message> field)
Checks if a specific field is set on the builder.
|
PMessageBuilder<?> |
PMessageBuilder.mutator(PField<Message> field)
Get the builder for the given message contained in this builder.
|
PMessageBuilder<Message> |
PMessageBuilder.set(PField<Message> field,
Object value)
Set the provided field value.
|
| Modifier and Type | Method and Description |
|---|---|
PField<T> |
PMessageDescriptor.fieldForId(int id) |
PField<T> |
PMessageDescriptor.fieldForName(String name) |
PField<T> |
PMessageDescriptor.fieldForPojoName(String pojoName) |
PField<T> |
PInterfaceDescriptor.findFieldById(int id) |
abstract PField<T> |
PMessageDescriptor.findFieldById(int id) |
PField<T> |
PInterfaceDescriptor.findFieldByName(String name) |
abstract PField<T> |
PMessageDescriptor.findFieldByName(String name) |
PField<T> |
PInterfaceDescriptor.findFieldByPojoName(String pojoName) |
abstract PField<T> |
PMessageDescriptor.findFieldByPojoName(String pojoName) |
PField<T>[] |
PInterfaceDescriptor.getFields() |
abstract PField<T>[] |
PMessageDescriptor.getFields() |
| Modifier and Type | Method and Description |
|---|---|
static String |
PField.asIfString(PField<?> field)
asIfString helper for interface fields.
|
static String |
PField.asString(PField<?> field)
asString helper for fields.
|
| Constructor and Description |
|---|
PInterfaceDescriptor(String programName,
String name,
PField<T>[] fields,
PMessageDescriptorProvider<?>... possibleTypes) |
| Modifier and Type | Method and Description |
|---|---|
static PField<?>[] |
MessageUtil.keyPathToFields(PMessageDescriptor<?> rootDescriptor,
String key)
Convert a key path to a list of consecutive fields for recursive lookup.
|
| Modifier and Type | Method and Description |
|---|---|
<M2 extends PMessage<M2>> |
MessageValidator.Builder.expect(PField<M> field,
PMessageDescriptor<M2> descriptor,
Consumer<MessageValidator.Builder<M2,E>> builderConsumer)
Deprecated.
Given the field and type descriptor (which must match the field type),
build an inner validator to check the value of the field.
|
<V> MessageValidation.Builder<M,E> |
MessageValidation.Builder.expectIfPresent(PField<M> field,
MessageValidation.Expectation<V> valueExpectation)
Given the field and type descriptor (which must match the field type),
build an inner validator to check the value of the field.
|
<V> MessageValidation.Builder<M,E> |
MessageValidation.Builder.expectIfPresent(PField<M> field,
MessageValidation.SimpleExpectation<V> valueExpectation)
Given the field and type descriptor (which must match the field type),
build an inner validator to check the value of the field.
|
<M2 extends PMessage<M2>> |
MessageValidation.Builder.expectIfPresent(PField<M> field,
PMessageDescriptor<M2> descriptor,
Consumer<MessageValidation.Builder<M2,E>> builderConsumer)
Given the field and type descriptor (which must match the field type),
build an inner validator to check the value of the field.
|
MessageValidation.Builder<M,E> |
MessageValidation.Builder.expectMissing(PField<M>... fields)
Expect field to be present on message.
|
MessageValidator.Builder<M,E> |
MessageValidator.Builder.expectMissing(PField<M>... fields)
Deprecated.
Expect field to be present on message.
|
MessageValidator.Builder<M,E> |
MessageValidator.Builder.expectMissing(String text,
PField<M> field)
Deprecated.
Expect field to be present on message.
|
MessageValidation.Builder<M,E> |
MessageValidation.Builder.expectPresent(PField<M>... fields)
Expect field to be present on message.
|
MessageValidator.Builder<M,E> |
MessageValidator.Builder.expectPresent(PField<M>... fields)
Deprecated.
Expect field to be present on message.
|
MessageValidator.Builder<M,E> |
MessageValidator.Builder.expectPresent(String text,
PField<M> field)
Deprecated.
Expect field to be present on message.
|
static <T> Optional<T> |
MessageUtil.getInMessage(PMessageOrBuilder<?> message,
PField<?>... fields)
Look up a key in the message structure.
|
static String |
MessageUtil.keyPath(PField<?>... fields)
Append field to the given path.
|
static String |
MessageUtil.keyPathAppend(String path,
PField<?> field)
Append field to the given path.
|
static <T> Optional<T> |
MessageUtil.optionalInMessage(PMessageOrBuilder<?> message,
PField<?>... fields)
Get a field value from a message with optional chaining.
|
| Constructor and Description |
|---|
MessageCollectionValidationExpectation(PField<BaseMessage> field,
MessageValidation<FieldMessage,E> validation) |
MessageMapValidationExpectation(PField<BaseMessage> field,
MessageValidation<FieldMessage,E> validation) |
Copyright © 2015–2020 morimekta.net. All rights reserved.