package {{package}}

{{#imports}}import {{import}}
{{/imports}}
import com.wordnik.swagger.client._
import apis._
import java.io.Closeable

class {{clientName}}(config: SwaggerConfig) extends Closeable {
  val locator = config.locator
  val name = config.name

  private[this] val client = transportClient

  protected def transportClient: TransportClient = new RestClient(config)

  {{#apiInfo}}
  {{#apis}}
  val {{name}} = new {{className}}(client, config)
  {{/apis}}
  {{/apiInfo}}

  def close() {
    client.close()
  }
}