#[non_exhaustive]pub struct BgpRoute {
pub as_paths: Vec<BgpRouteAsPath>,
pub communities: Vec<String>,
pub destination: Option<BgpRouteNetworkLayerReachabilityInformation>,
pub med: Option<u32>,
pub origin: Option<Origin>,
/* private fields */
}Available on crate feature
routers only.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.as_paths: Vec<BgpRouteAsPath>Output only. [Output only] AS-PATH for the route
communities: Vec<String>Output only. [Output only] BGP communities in human-readable A:B format.
destination: Option<BgpRouteNetworkLayerReachabilityInformation>Output only. [Output only] Destination IP range for the route, in human-readable CIDR format
med: Option<u32>Output only. [Output only] BGP multi-exit discriminator
origin: Option<Origin>Output only. [Output only] BGP origin (EGP, IGP or INCOMPLETE)
Implementations§
Source§impl BgpRoute
impl BgpRoute
pub fn new() -> Self
Sourcepub fn set_as_paths<T, V>(self, v: T) -> Self
pub fn set_as_paths<T, V>(self, v: T) -> Self
Sourcepub fn set_communities<T, V>(self, v: T) -> Self
pub fn set_communities<T, V>(self, v: T) -> Self
Sourcepub fn set_destination<T>(self, v: T) -> Selfwhere
T: Into<BgpRouteNetworkLayerReachabilityInformation>,
pub fn set_destination<T>(self, v: T) -> Selfwhere
T: Into<BgpRouteNetworkLayerReachabilityInformation>,
Sets the value of destination.
§Example
ⓘ
use google_cloud_compute_v1::model::BgpRouteNetworkLayerReachabilityInformation;
let x = BgpRoute::new().set_destination(BgpRouteNetworkLayerReachabilityInformation::default()/* use setters */);Sourcepub fn set_or_clear_destination<T>(self, v: Option<T>) -> Selfwhere
T: Into<BgpRouteNetworkLayerReachabilityInformation>,
pub fn set_or_clear_destination<T>(self, v: Option<T>) -> Selfwhere
T: Into<BgpRouteNetworkLayerReachabilityInformation>,
Sets or clears the value of destination.
§Example
ⓘ
use google_cloud_compute_v1::model::BgpRouteNetworkLayerReachabilityInformation;
let x = BgpRoute::new().set_or_clear_destination(Some(BgpRouteNetworkLayerReachabilityInformation::default()/* use setters */));
let x = BgpRoute::new().set_or_clear_destination(None::<BgpRouteNetworkLayerReachabilityInformation>);Sourcepub fn set_or_clear_med<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_med<T>(self, v: Option<T>) -> Self
Sourcepub fn set_origin<T>(self, v: T) -> Self
pub fn set_origin<T>(self, v: T) -> Self
Sourcepub fn set_or_clear_origin<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_origin<T>(self, v: Option<T>) -> Self
Sets or clears the value of origin.
§Example
ⓘ
use google_cloud_compute_v1::model::bgp_route::Origin;
let x0 = BgpRoute::new().set_or_clear_origin(Some(Origin::BgpOriginIgp));
let x1 = BgpRoute::new().set_or_clear_origin(Some(Origin::BgpOriginIncomplete));
let x_none = BgpRoute::new().set_or_clear_origin(None::<Origin>);Trait Implementations§
impl StructuralPartialEq for BgpRoute
Auto Trait Implementations§
impl Freeze for BgpRoute
impl RefUnwindSafe for BgpRoute
impl Send for BgpRoute
impl Sync for BgpRoute
impl Unpin for BgpRoute
impl UnwindSafe for BgpRoute
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