Groovy Documentation

org.linkedin.glu.agent.rest.client
[Groovy] Interface RestClientFactory


interface RestClientFactory

Authors:
yan@pongasoft.com


Method Summary
Client createRestClient(java.net.URI uri)

Creates and return the rest client.

java.lang.Object withRestClient(java.net.URI uri, groovy.lang.Closure closure)

Calls the closure with a client that has been started and make sure it gets closed.

 

Method Detail

createRestClient

Client createRestClient(java.net.URI uri)
Creates and return the rest client. The caller is in charge of managing its lifecycle


withRestClient

java.lang.Object withRestClient(java.net.URI uri, groovy.lang.Closure closure)
Calls the closure with a client that has been started and make sure it gets closed.
Returns:
whatever the closure returns


 

Groovy Documentation