Check if outgoing Request can be created
This use case is intended to check if a LocalRequest can be created based on a given Request for a given peer
.
This use case should be executed before actually attempting to create the outgoing Request, because a more precise error description is provided in the case of a faulty Request.
Parameters
- The
content
as a Request for the to be created LocalRequest. - The
peer
is the address for which the LocalRequest should be created. There can only be one peer per LocalRequest. Even though thepeer
parameter is optional, it is recommended to specify it whenever possible. This allows additional validation rules to execute. When sending a Request via a Message, thepeer
receiving it is always known.
On Success
- Returns a
RequestValidationResult
that indicates if the given Request is valid.
On Failure
- The
RequestValidationResult
cannot be created if the Request specified ascontent
is malformed.