#[non_exhaustive]pub struct CreateOpenAPIOptionalParams {
pub openapi_spec_file: Option<Vec<u8>>,
}
Expand description
CreateOpenAPIOptionalParams is a struct for passing parameters to the method APIManagementAPI::create_open_api
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. }
syntax; cannot be matched against without a wildcard ..
; and struct update syntax will not work.openapi_spec_file: Option<Vec<u8>>
Binary OpenAPI
spec file
Implementations§
Source§impl CreateOpenAPIOptionalParams
impl CreateOpenAPIOptionalParams
Sourcepub fn openapi_spec_file(self, value: Vec<u8>) -> Self
pub fn openapi_spec_file(self, value: Vec<u8>) -> Self
Binary OpenAPI
spec file
Examples found in repository?
examples/v2_api-management_CreateOpenAPI.rs (line 15)
8async fn main() {
9 let mut configuration = datadog::Configuration::new();
10 configuration.set_unstable_operation_enabled("v2.CreateOpenAPI", true);
11 let api = APIManagementAPI::with_config(configuration);
12 let resp = api
13 .create_open_api(
14 CreateOpenAPIOptionalParams::default()
15 .openapi_spec_file(fs::read("openapi-spec.yaml").unwrap()),
16 )
17 .await;
18 if let Ok(value) = resp {
19 println!("{:#?}", value);
20 } else {
21 println!("{:#?}", resp.unwrap_err());
22 }
23}
Trait Implementations§
Source§impl Clone for CreateOpenAPIOptionalParams
impl Clone for CreateOpenAPIOptionalParams
Source§fn clone(&self) -> CreateOpenAPIOptionalParams
fn clone(&self) -> CreateOpenAPIOptionalParams
Returns a duplicate of the value. Read more
1.0.0 · Source§const fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for CreateOpenAPIOptionalParams
impl Debug for CreateOpenAPIOptionalParams
Source§impl Default for CreateOpenAPIOptionalParams
impl Default for CreateOpenAPIOptionalParams
Source§fn default() -> CreateOpenAPIOptionalParams
fn default() -> CreateOpenAPIOptionalParams
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for CreateOpenAPIOptionalParams
impl RefUnwindSafe for CreateOpenAPIOptionalParams
impl Send for CreateOpenAPIOptionalParams
impl Sync for CreateOpenAPIOptionalParams
impl Unpin for CreateOpenAPIOptionalParams
impl UnwindSafe for CreateOpenAPIOptionalParams
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more