added autogenerated rust server code
This commit is contained in:
26
src/apis/client.rs
Normal file
26
src/apis/client.rs
Normal file
@@ -0,0 +1,26 @@
|
||||
use std::rc::Rc;
|
||||
|
||||
use hyper;
|
||||
use super::configuration::Configuration;
|
||||
|
||||
pub struct APIClient<C: hyper::client::Connect> {
|
||||
configuration: Rc<Configuration<C>>,
|
||||
default_api: Box<::apis::DefaultApi>,
|
||||
}
|
||||
|
||||
impl<C: hyper::client::Connect> APIClient<C> {
|
||||
pub fn new(configuration: Configuration<C>) -> APIClient<C> {
|
||||
let rc = Rc::new(configuration);
|
||||
|
||||
APIClient {
|
||||
configuration: rc.clone(),
|
||||
default_api: Box::new(::apis::DefaultApiClient::new(rc.clone())),
|
||||
}
|
||||
}
|
||||
|
||||
pub fn default_api(&self) -> &::apis::DefaultApi{
|
||||
self.default_api.as_ref()
|
||||
}
|
||||
|
||||
|
||||
}
|
Reference in New Issue
Block a user