Package org.web3j.protocol.websocket
Class WebSocketSubscription<T>
- java.lang.Object
-
- org.web3j.protocol.websocket.WebSocketSubscription<T>
-
- Type Parameters:
T
- type of a data item that should be returned by a WebSocket subscription.
public class WebSocketSubscription<T> extends java.lang.Object
Objects necessary to process a new item received via a WebSocket subscription.
-
-
Constructor Summary
Constructors Constructor Description WebSocketSubscription(io.reactivex.subjects.BehaviorSubject<T> subject, java.lang.Class<T> responseType)
Creates WebSocketSubscription.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Class<T>
getResponseType()
io.reactivex.subjects.BehaviorSubject<T>
getSubject()
-
-
-
Constructor Detail
-
WebSocketSubscription
public WebSocketSubscription(io.reactivex.subjects.BehaviorSubject<T> subject, java.lang.Class<T> responseType)
Creates WebSocketSubscription.- Parameters:
subject
- used to send new data items to listenersresponseType
- type of a data item returned by a WebSocket subscription
-
-