pub struct GitlabBuilder { /* private fields */ }Implementations§
Source§impl GitlabBuilder
impl GitlabBuilder
Sourcepub fn new_unauthenticated<H>(host: H) -> Self
pub fn new_unauthenticated<H>(host: H) -> Self
Create a new unauthenticated Gitlab API client builder.
Sourcepub fn new_with_job_token<H, T>(host: H, token: T) -> Self
pub fn new_with_job_token<H, T>(host: H, token: T) -> Self
Create a new Gitlab API client builder with job token.
Sourcepub fn insecure(&mut self) -> &mut Self
pub fn insecure(&mut self) -> &mut Self
Switch to an insecure protocol (http instead of https).
pub fn cert_insecure(&mut self) -> &mut Self
Sourcepub fn oauth2_token(&mut self) -> &mut Self
pub fn oauth2_token(&mut self) -> &mut Self
Switch to using an OAuth2 token instead of a personal access token
Sourcepub fn job_token(&mut self) -> &mut Self
pub fn job_token(&mut self) -> &mut Self
Switch to using an job token instead of a personal access token
Sourcepub fn client_identity_from_der(
&mut self,
der: &[u8],
password: &str,
) -> &mut Self
pub fn client_identity_from_der( &mut self, der: &[u8], password: &str, ) -> &mut Self
Authenticate to Gitlab with the provided DER-formatted PKCS#12 archive.
Sourcepub fn client_identity_from_pem(&mut self, pem: &[u8]) -> &mut Self
pub fn client_identity_from_pem(&mut self, pem: &[u8]) -> &mut Self
Authenticate to Gitlab with the provided PEM-encoded private key and certificate.
Sourcepub fn user_agent<U>(&mut self, user_agent: U) -> &mut Self
pub fn user_agent<U>(&mut self, user_agent: U) -> &mut Self
HTTP user agent to use for API calls
pub fn build(&self) -> Result<Gitlab, GitlabError>
pub async fn build_async(&self) -> Result<AsyncGitlab, GitlabError>
Auto Trait Implementations§
impl Freeze for GitlabBuilder
impl RefUnwindSafe for GitlabBuilder
impl Send for GitlabBuilder
impl Sync for GitlabBuilder
impl Unpin for GitlabBuilder
impl UnsafeUnpin for GitlabBuilder
impl UnwindSafe for GitlabBuilder
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
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more