public class ResponseHeadersSnippet extends AbstractHeadersSnippet
Snippet that documents the headers in a response.HeaderDocumentation.responseHeaders(HeaderDescriptor...),
HeaderDocumentation.responseHeaders(Map, HeaderDescriptor...)| Modifier | Constructor and Description |
|---|---|
protected |
ResponseHeadersSnippet(List<HeaderDescriptor> descriptors)
Creates a new
ResponseHeadersSnippet that will document the headers in the
response using the given descriptors. |
protected |
ResponseHeadersSnippet(List<HeaderDescriptor> descriptors,
Map<String,Object> attributes)
Creates a new
ResponseHeadersSnippet that will document the headers in the
response using the given descriptors. |
| Modifier and Type | Method and Description |
|---|---|
protected Set<String> |
extractActualHeaders(Operation operation)
Extracts the names of the headers from the request or response of the given
operation. |
createModel, createModelForDescriptor, findMissingHeaders, getHeaderDescriptorsdocument, getAttributes, getSnippetNameprotected ResponseHeadersSnippet(List<HeaderDescriptor> descriptors)
ResponseHeadersSnippet that will document the headers in the
response using the given descriptors.descriptors - the descriptorsprotected ResponseHeadersSnippet(List<HeaderDescriptor> descriptors, Map<String,Object> attributes)
ResponseHeadersSnippet that will document the headers in the
response using the given descriptors. The given attributes will be
included in the model during template rendering.descriptors - the descriptorsattributes - the additional attributesprotected Set<String> extractActualHeaders(Operation operation)
AbstractHeadersSnippetoperation.extractActualHeaders in class AbstractHeadersSnippetoperation - the operation