Enum jenkins_api::View
[−]
[src]
pub enum View { ListView { description: Option<String>, name: String, url: String, jobs: Vec<ShortJob>, property: Vec<Property>, }, Unknown { class: Option<String>, }, }
A Jenkins View
with a list of ShortJob
Variants
ListView
A view listing jobs
Fields of ListView
description: Option<String> | Description of the view |
name: String | Name of the view |
url: String | URL for the view |
jobs: Vec<ShortJob> | List of jobs in the view |
property: Vec<Property> | Properties of the view |
Unknown
Default case used when none other matched
Fields of Unknown
class: Option<String> | _class provided by Jenkins |
Methods
impl View
[src]
pub fn name(&self) -> Result<&str, Error>
[src]
Get the name of the view
pub fn jobs(&self) -> Result<&Vec<ShortJob>, Error>
[src]
Get the jobs from the view
pub fn add_job(
&self,
jenkins_client: &Jenkins,
job_name: &str
) -> Result<(), Error>
[src]
&self,
jenkins_client: &Jenkins,
job_name: &str
) -> Result<(), Error>
Add the job job_name
to this view
pub fn remove_job(
&self,
jenkins_client: &Jenkins,
job_name: &str
) -> Result<(), Error>
[src]
&self,
jenkins_client: &Jenkins,
job_name: &str
) -> Result<(), Error>
Remove the job job_name
from this view
Trait Implementations
impl Debug for View
[src]
fn fmt(&self, __arg_0: &mut Formatter) -> Result
[src]
Formats the value using the given formatter. Read more
impl<'de> Deserialize<'de> for View
[src]
fn deserialize<D>(deserializer: D) -> Result<View, D::Error> where
D: Deserializer<'de>,
[src]
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more