public interface ReaderInterceptorContext extends InterceptorContext
ReaderInterceptor
によって使用されるコンテキストクラス。このコンテキストクラスの getter および setter は、インターセプトされたメソッドのパラメーターに対応します。ReaderInterceptor
, MessageBodyReader
修飾子と型 | メソッドと説明 |
---|---|
MultivaluedMap<StringSE, StringSE> | getHeaders() HTTP ヘッダーの可変マップを取得します。 |
InputStreamSE | getInputStream() 読み込まれるオブジェクトの入力ストリームを取得します。 |
ObjectSE | proceed() チェーンの次のインターセプターに進みます。 |
void | setInputStream(InputStreamSE is) 読み込むオブジェクトの入力ストリームを設定します。 |
getAnnotations, getGenericType, getMediaType, getProperty, getPropertyNames, getType, removeProperty, setAnnotations, setGenericType, setMediaType, setProperty, setType
ObjectSE proceed() throws IOExceptionSE, WebApplicationException
MessageBodyReader.readFrom(java.lang.Class<T>, java.lang.reflect.Type, java.lang.annotation.Annotation[], javax.ws.rs.core.MediaType, javax.ws.rs.core.MultivaluedMap<java.lang.String, java.lang.String>, java.io.InputStream)
が呼び出されます。IOExceptionSE
- IO エラーが発生した場合、またはラップされた MessageBodyReader.readFrom
メソッドによってスローされた場合。WebApplicationException
- ラップされた MessageBodyReader.readFrom
メソッドによってスローされます。InputStreamSE getInputStream()
void setInputStream(InputStreamSE is)
is
- 新しい入力ストリーム。MultivaluedMap<StringSE,StringSE> getHeaders()
ヘッダーは変更可能ですが、context.proceed()
の呼び出しが戻ると、reader interceptor
は通常、ヘッダーの変更をロールバックして、インターセプターの呼び出しによる外部から見える副作用を回避する必要があります。
Copyright © 2019 Eclipse Foundation.
Use is subject to license terms.