#[non_exhaustive]pub struct FileLocation {
pub file_path: String,
pub layer_details: Option<LayerDetails>,
/* private fields */
}Expand description
Indicates the location at which a package was found.
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.file_path: StringFor jars that are contained inside .war files, this filepath can indicate the path to war file combined with the path to jar file.
layer_details: Option<LayerDetails>Each package found in a file should have its own layer metadata (that is, information from the origin layer of the package).
Implementations§
Source§impl FileLocation
impl FileLocation
pub fn new() -> Self
Sourcepub fn set_file_path<T: Into<String>>(self, v: T) -> Self
pub fn set_file_path<T: Into<String>>(self, v: T) -> Self
Sourcepub fn set_layer_details<T>(self, v: T) -> Selfwhere
T: Into<LayerDetails>,
pub fn set_layer_details<T>(self, v: T) -> Selfwhere
T: Into<LayerDetails>,
Sets the value of layer_details.
§Example
ⓘ
use google_cloud_grafeas_v1::model::LayerDetails;
let x = FileLocation::new().set_layer_details(LayerDetails::default()/* use setters */);Sourcepub fn set_or_clear_layer_details<T>(self, v: Option<T>) -> Selfwhere
T: Into<LayerDetails>,
pub fn set_or_clear_layer_details<T>(self, v: Option<T>) -> Selfwhere
T: Into<LayerDetails>,
Sets or clears the value of layer_details.
§Example
ⓘ
use google_cloud_grafeas_v1::model::LayerDetails;
let x = FileLocation::new().set_or_clear_layer_details(Some(LayerDetails::default()/* use setters */));
let x = FileLocation::new().set_or_clear_layer_details(None::<LayerDetails>);Trait Implementations§
Source§impl Clone for FileLocation
impl Clone for FileLocation
Source§fn clone(&self) -> FileLocation
fn clone(&self) -> FileLocation
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for FileLocation
impl Debug for FileLocation
Source§impl Default for FileLocation
impl Default for FileLocation
Source§fn default() -> FileLocation
fn default() -> FileLocation
Returns the “default value” for a type. Read more
Source§impl Message for FileLocation
impl Message for FileLocation
Source§impl PartialEq for FileLocation
impl PartialEq for FileLocation
impl StructuralPartialEq for FileLocation
Auto Trait Implementations§
impl Freeze for FileLocation
impl RefUnwindSafe for FileLocation
impl Send for FileLocation
impl Sync for FileLocation
impl Unpin for FileLocation
impl UnsafeUnpin for FileLocation
impl UnwindSafe for FileLocation
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