Class JerseyClientFactory.CloseableClient

java.lang.Object
au.net.causal.shoelaces.jerseyclient.JerseyClientFactory.CloseableClient
All Implemented Interfaces:
java.lang.AutoCloseable
Enclosing interface:
JerseyClientFactory

public static class JerseyClientFactory.CloseableClient
extends java.lang.Object
implements java.lang.AutoCloseable
Wrapper for clients that makes them easy to use with try-with-resources.
  • Constructor Summary

    Constructors 
    Constructor Description
    CloseableClient​(javax.ws.rs.client.Client client)  
  • Method Summary

    Modifier and Type Method Description
    javax.ws.rs.client.Client client()  
    void close()  

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • CloseableClient

      public CloseableClient​(javax.ws.rs.client.Client client)
  • Method Details

    • client

      public javax.ws.rs.client.Client client()
      Returns:
      the actual client.
    • close

      public void close()
      Specified by:
      close in interface java.lang.AutoCloseable