Skip to content

Commit

Permalink
updated readme formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
TheCookieLab committed Mar 14, 2018
1 parent 185656c commit 1897ba8
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -224,12 +224,11 @@ Using Poloniex's websocket interface is also very simple.
The following example sets up subscriptions to the general ticker as well as the USDT_ETH order book / trades, and then runs for 60 seconds:

```java
try (WSSClient wssClient = new WSSClient(ENDPOINT_URL))
{
try (WSSClient wssClient = new WSSClient(ENDPOINT_URL)) {
wssClient.addSubscription(PoloniexWSSSubscription.USDT_ETH, new LoggerMessageHandler());
wssClient.addSubscription(PoloniexWSSSubscription.TICKER, new TickerMessageHandler());
wssClient.run(60000);
}
}
```

To setup your own subscription handler, just implement the IMessageHandler interface and do your logic within the `public void handle(String message)` method.
Expand Down

0 comments on commit 1897ba8

Please sign in to comment.