Package org.apache.sling.distribution

## Interface DistributionResponse

    @ProviderType
    public interface DistributionResponse

A `DistributionResponse` represents the outcome of a `DistributionRequest` as handled by a certain distribution agent. Such a response will include the `state` of the `request` and optionally a message for more verbose information about the outcome of the request and additional `properties`.

### Method Summary

All Methods Instance Methods Abstract Methods
`DistributionResponseInfo` `getDistributionInfo()` returns additional properties related to the `DistributionRequest`
`String` `getMessage()` returns a verbose message of the response
`DistributionRequestState` `getState()` returns the state of the associated `DistributionRequest`
`boolean` `isSuccessful()` returns the status of the request, whether it is successful or not.

### Method Detail

#### isSuccessful

    boolean isSuccessful()

returns the status of the request, whether it is successful or not. A successful request it is not necessarily distributed, it is just successfully received by the agent. To check the exact state of the request one can retrieve it with `getState`

Returns:
  `true` if request has been accepted by the agent.

#### getState

    @Nonnull
    DistributionRequestState getState()

returns the state of the associated `DistributionRequest`

Returns:
  the state of the associated request

#### getMessage

    @Nullable
    String getMessage()

returns a verbose message of the response

Returns:
  a message associated with this response holding information about e.g. why distribution execution failed, etc.

#### getDistributionInfo

    @Nonnull
    DistributionResponseInfo getDistributionInfo()

returns additional properties related to the `DistributionRequest`

Returns:
  additional properties