#[non_exhaustive]pub struct Connection {Show 14 fields
pub name: String,
pub create_time: Option<Timestamp>,
pub update_time: Option<Timestamp>,
pub delete_time: Option<Timestamp>,
pub labels: HashMap<String, String>,
pub installation_state: Option<InstallationState>,
pub disabled: bool,
pub reconciling: bool,
pub annotations: HashMap<String, String>,
pub etag: String,
pub uid: String,
pub crypto_key_config: Option<CryptoKeyConfig>,
pub git_proxy_config: Option<GitProxyConfig>,
pub connection_config: Option<ConnectionConfig>,
/* private fields */
}Expand description
Message describing Connection object
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.name: StringIdentifier. The resource name of the connection, in the format
projects/{project}/locations/{location}/connections/{connection_id}.
create_time: Option<Timestamp>Output only. [Output only] Create timestamp
update_time: Option<Timestamp>Output only. [Output only] Update timestamp
delete_time: Option<Timestamp>Output only. [Output only] Delete timestamp
labels: HashMap<String, String>Optional. Labels as key value pairs
installation_state: Option<InstallationState>Output only. Installation state of the Connection.
disabled: boolOptional. If disabled is set to true, functionality is disabled for this connection. Repository based API methods and webhooks processing for repositories in this connection will be disabled.
reconciling: boolOutput only. Set to true when the connection is being set up or updated in the background.
annotations: HashMap<String, String>Optional. Allows clients to store small amounts of arbitrary data.
etag: StringOptional. This checksum is computed by the server based on the value of other fields, and may be sent on update and delete requests to ensure the client has an up-to-date value before proceeding.
uid: StringOutput only. A system-assigned unique identifier for the Connection.
crypto_key_config: Option<CryptoKeyConfig>Optional. The crypto key configuration. This field is used by the Customer-Managed Encryption Keys (CMEK) feature.
git_proxy_config: Option<GitProxyConfig>Optional. Configuration for the git proxy feature. Enabling the git proxy allows clients to perform git operations on the repositories linked in the connection.
connection_config: Option<ConnectionConfig>Configuration for the connection depending on the type of provider.
Implementations§
Source§impl Connection
impl Connection
Sourcepub fn set_create_time<T>(self, v: T) -> Self
pub fn set_create_time<T>(self, v: T) -> Self
Sets the value of create_time.
§Example
use wkt::Timestamp;
let x = Connection::new().set_create_time(Timestamp::default()/* use setters */);Sourcepub fn set_or_clear_create_time<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_create_time<T>(self, v: Option<T>) -> Self
Sets or clears the value of create_time.
§Example
use wkt::Timestamp;
let x = Connection::new().set_or_clear_create_time(Some(Timestamp::default()/* use setters */));
let x = Connection::new().set_or_clear_create_time(None::<Timestamp>);Sourcepub fn set_update_time<T>(self, v: T) -> Self
pub fn set_update_time<T>(self, v: T) -> Self
Sets the value of update_time.
§Example
use wkt::Timestamp;
let x = Connection::new().set_update_time(Timestamp::default()/* use setters */);Sourcepub fn set_or_clear_update_time<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_update_time<T>(self, v: Option<T>) -> Self
Sets or clears the value of update_time.
§Example
use wkt::Timestamp;
let x = Connection::new().set_or_clear_update_time(Some(Timestamp::default()/* use setters */));
let x = Connection::new().set_or_clear_update_time(None::<Timestamp>);Sourcepub fn set_delete_time<T>(self, v: T) -> Self
pub fn set_delete_time<T>(self, v: T) -> Self
Sets the value of delete_time.
§Example
use wkt::Timestamp;
let x = Connection::new().set_delete_time(Timestamp::default()/* use setters */);Sourcepub fn set_or_clear_delete_time<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_delete_time<T>(self, v: Option<T>) -> Self
Sets or clears the value of delete_time.
§Example
use wkt::Timestamp;
let x = Connection::new().set_or_clear_delete_time(Some(Timestamp::default()/* use setters */));
let x = Connection::new().set_or_clear_delete_time(None::<Timestamp>);Sourcepub fn set_labels<T, K, V>(self, v: T) -> Self
pub fn set_labels<T, K, V>(self, v: T) -> Self
Sourcepub fn set_installation_state<T>(self, v: T) -> Selfwhere
T: Into<InstallationState>,
pub fn set_installation_state<T>(self, v: T) -> Selfwhere
T: Into<InstallationState>,
Sets the value of installation_state.
§Example
use google_cloud_developerconnect_v1::model::InstallationState;
let x = Connection::new().set_installation_state(InstallationState::default()/* use setters */);Sourcepub fn set_or_clear_installation_state<T>(self, v: Option<T>) -> Selfwhere
T: Into<InstallationState>,
pub fn set_or_clear_installation_state<T>(self, v: Option<T>) -> Selfwhere
T: Into<InstallationState>,
Sets or clears the value of installation_state.
§Example
use google_cloud_developerconnect_v1::model::InstallationState;
let x = Connection::new().set_or_clear_installation_state(Some(InstallationState::default()/* use setters */));
let x = Connection::new().set_or_clear_installation_state(None::<InstallationState>);Sourcepub fn set_disabled<T: Into<bool>>(self, v: T) -> Self
pub fn set_disabled<T: Into<bool>>(self, v: T) -> Self
Sourcepub fn set_reconciling<T: Into<bool>>(self, v: T) -> Self
pub fn set_reconciling<T: Into<bool>>(self, v: T) -> Self
Sourcepub fn set_annotations<T, K, V>(self, v: T) -> Self
pub fn set_annotations<T, K, V>(self, v: T) -> Self
Sets the value of annotations.
§Example
let x = Connection::new().set_annotations([
("key0", "abc"),
("key1", "xyz"),
]);Sourcepub fn set_crypto_key_config<T>(self, v: T) -> Selfwhere
T: Into<CryptoKeyConfig>,
pub fn set_crypto_key_config<T>(self, v: T) -> Selfwhere
T: Into<CryptoKeyConfig>,
Sets the value of crypto_key_config.
§Example
use google_cloud_developerconnect_v1::model::CryptoKeyConfig;
let x = Connection::new().set_crypto_key_config(CryptoKeyConfig::default()/* use setters */);Sourcepub fn set_or_clear_crypto_key_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<CryptoKeyConfig>,
pub fn set_or_clear_crypto_key_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<CryptoKeyConfig>,
Sets or clears the value of crypto_key_config.
§Example
use google_cloud_developerconnect_v1::model::CryptoKeyConfig;
let x = Connection::new().set_or_clear_crypto_key_config(Some(CryptoKeyConfig::default()/* use setters */));
let x = Connection::new().set_or_clear_crypto_key_config(None::<CryptoKeyConfig>);Sourcepub fn set_git_proxy_config<T>(self, v: T) -> Selfwhere
T: Into<GitProxyConfig>,
pub fn set_git_proxy_config<T>(self, v: T) -> Selfwhere
T: Into<GitProxyConfig>,
Sets the value of git_proxy_config.
§Example
use google_cloud_developerconnect_v1::model::GitProxyConfig;
let x = Connection::new().set_git_proxy_config(GitProxyConfig::default()/* use setters */);Sourcepub fn set_or_clear_git_proxy_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<GitProxyConfig>,
pub fn set_or_clear_git_proxy_config<T>(self, v: Option<T>) -> Selfwhere
T: Into<GitProxyConfig>,
Sets or clears the value of git_proxy_config.
§Example
use google_cloud_developerconnect_v1::model::GitProxyConfig;
let x = Connection::new().set_or_clear_git_proxy_config(Some(GitProxyConfig::default()/* use setters */));
let x = Connection::new().set_or_clear_git_proxy_config(None::<GitProxyConfig>);Sourcepub fn set_connection_config<T: Into<Option<ConnectionConfig>>>(
self,
v: T,
) -> Self
pub fn set_connection_config<T: Into<Option<ConnectionConfig>>>( self, v: T, ) -> Self
Sets the value of connection_config.
Note that all the setters affecting connection_config are mutually
exclusive.
§Example
use google_cloud_developerconnect_v1::model::GitHubConfig;
let x = Connection::new().set_connection_config(Some(
google_cloud_developerconnect_v1::model::connection::ConnectionConfig::GithubConfig(GitHubConfig::default().into())));Sourcepub fn github_config(&self) -> Option<&Box<GitHubConfig>>
pub fn github_config(&self) -> Option<&Box<GitHubConfig>>
The value of connection_config
if it holds a GithubConfig, None if the field is not set or
holds a different branch.
Sourcepub fn set_github_config<T: Into<Box<GitHubConfig>>>(self, v: T) -> Self
pub fn set_github_config<T: Into<Box<GitHubConfig>>>(self, v: T) -> Self
Sets the value of connection_config
to hold a GithubConfig.
Note that all the setters affecting connection_config are
mutually exclusive.
§Example
use google_cloud_developerconnect_v1::model::GitHubConfig;
let x = Connection::new().set_github_config(GitHubConfig::default()/* use setters */);
assert!(x.github_config().is_some());
assert!(x.github_enterprise_config().is_none());
assert!(x.gitlab_config().is_none());
assert!(x.gitlab_enterprise_config().is_none());
assert!(x.bitbucket_data_center_config().is_none());
assert!(x.bitbucket_cloud_config().is_none());
assert!(x.secure_source_manager_instance_config().is_none());
assert!(x.http_config().is_none());Sourcepub fn github_enterprise_config(&self) -> Option<&Box<GitHubEnterpriseConfig>>
pub fn github_enterprise_config(&self) -> Option<&Box<GitHubEnterpriseConfig>>
The value of connection_config
if it holds a GithubEnterpriseConfig, None if the field is not set or
holds a different branch.
Sourcepub fn set_github_enterprise_config<T: Into<Box<GitHubEnterpriseConfig>>>(
self,
v: T,
) -> Self
pub fn set_github_enterprise_config<T: Into<Box<GitHubEnterpriseConfig>>>( self, v: T, ) -> Self
Sets the value of connection_config
to hold a GithubEnterpriseConfig.
Note that all the setters affecting connection_config are
mutually exclusive.
§Example
use google_cloud_developerconnect_v1::model::GitHubEnterpriseConfig;
let x = Connection::new().set_github_enterprise_config(GitHubEnterpriseConfig::default()/* use setters */);
assert!(x.github_enterprise_config().is_some());
assert!(x.github_config().is_none());
assert!(x.gitlab_config().is_none());
assert!(x.gitlab_enterprise_config().is_none());
assert!(x.bitbucket_data_center_config().is_none());
assert!(x.bitbucket_cloud_config().is_none());
assert!(x.secure_source_manager_instance_config().is_none());
assert!(x.http_config().is_none());Sourcepub fn gitlab_config(&self) -> Option<&Box<GitLabConfig>>
pub fn gitlab_config(&self) -> Option<&Box<GitLabConfig>>
The value of connection_config
if it holds a GitlabConfig, None if the field is not set or
holds a different branch.
Sourcepub fn set_gitlab_config<T: Into<Box<GitLabConfig>>>(self, v: T) -> Self
pub fn set_gitlab_config<T: Into<Box<GitLabConfig>>>(self, v: T) -> Self
Sets the value of connection_config
to hold a GitlabConfig.
Note that all the setters affecting connection_config are
mutually exclusive.
§Example
use google_cloud_developerconnect_v1::model::GitLabConfig;
let x = Connection::new().set_gitlab_config(GitLabConfig::default()/* use setters */);
assert!(x.gitlab_config().is_some());
assert!(x.github_config().is_none());
assert!(x.github_enterprise_config().is_none());
assert!(x.gitlab_enterprise_config().is_none());
assert!(x.bitbucket_data_center_config().is_none());
assert!(x.bitbucket_cloud_config().is_none());
assert!(x.secure_source_manager_instance_config().is_none());
assert!(x.http_config().is_none());Sourcepub fn gitlab_enterprise_config(&self) -> Option<&Box<GitLabEnterpriseConfig>>
pub fn gitlab_enterprise_config(&self) -> Option<&Box<GitLabEnterpriseConfig>>
The value of connection_config
if it holds a GitlabEnterpriseConfig, None if the field is not set or
holds a different branch.
Sourcepub fn set_gitlab_enterprise_config<T: Into<Box<GitLabEnterpriseConfig>>>(
self,
v: T,
) -> Self
pub fn set_gitlab_enterprise_config<T: Into<Box<GitLabEnterpriseConfig>>>( self, v: T, ) -> Self
Sets the value of connection_config
to hold a GitlabEnterpriseConfig.
Note that all the setters affecting connection_config are
mutually exclusive.
§Example
use google_cloud_developerconnect_v1::model::GitLabEnterpriseConfig;
let x = Connection::new().set_gitlab_enterprise_config(GitLabEnterpriseConfig::default()/* use setters */);
assert!(x.gitlab_enterprise_config().is_some());
assert!(x.github_config().is_none());
assert!(x.github_enterprise_config().is_none());
assert!(x.gitlab_config().is_none());
assert!(x.bitbucket_data_center_config().is_none());
assert!(x.bitbucket_cloud_config().is_none());
assert!(x.secure_source_manager_instance_config().is_none());
assert!(x.http_config().is_none());Sourcepub fn bitbucket_data_center_config(
&self,
) -> Option<&Box<BitbucketDataCenterConfig>>
pub fn bitbucket_data_center_config( &self, ) -> Option<&Box<BitbucketDataCenterConfig>>
The value of connection_config
if it holds a BitbucketDataCenterConfig, None if the field is not set or
holds a different branch.
Sourcepub fn set_bitbucket_data_center_config<T: Into<Box<BitbucketDataCenterConfig>>>(
self,
v: T,
) -> Self
pub fn set_bitbucket_data_center_config<T: Into<Box<BitbucketDataCenterConfig>>>( self, v: T, ) -> Self
Sets the value of connection_config
to hold a BitbucketDataCenterConfig.
Note that all the setters affecting connection_config are
mutually exclusive.
§Example
use google_cloud_developerconnect_v1::model::BitbucketDataCenterConfig;
let x = Connection::new().set_bitbucket_data_center_config(BitbucketDataCenterConfig::default()/* use setters */);
assert!(x.bitbucket_data_center_config().is_some());
assert!(x.github_config().is_none());
assert!(x.github_enterprise_config().is_none());
assert!(x.gitlab_config().is_none());
assert!(x.gitlab_enterprise_config().is_none());
assert!(x.bitbucket_cloud_config().is_none());
assert!(x.secure_source_manager_instance_config().is_none());
assert!(x.http_config().is_none());Sourcepub fn bitbucket_cloud_config(&self) -> Option<&Box<BitbucketCloudConfig>>
pub fn bitbucket_cloud_config(&self) -> Option<&Box<BitbucketCloudConfig>>
The value of connection_config
if it holds a BitbucketCloudConfig, None if the field is not set or
holds a different branch.
Sourcepub fn set_bitbucket_cloud_config<T: Into<Box<BitbucketCloudConfig>>>(
self,
v: T,
) -> Self
pub fn set_bitbucket_cloud_config<T: Into<Box<BitbucketCloudConfig>>>( self, v: T, ) -> Self
Sets the value of connection_config
to hold a BitbucketCloudConfig.
Note that all the setters affecting connection_config are
mutually exclusive.
§Example
use google_cloud_developerconnect_v1::model::BitbucketCloudConfig;
let x = Connection::new().set_bitbucket_cloud_config(BitbucketCloudConfig::default()/* use setters */);
assert!(x.bitbucket_cloud_config().is_some());
assert!(x.github_config().is_none());
assert!(x.github_enterprise_config().is_none());
assert!(x.gitlab_config().is_none());
assert!(x.gitlab_enterprise_config().is_none());
assert!(x.bitbucket_data_center_config().is_none());
assert!(x.secure_source_manager_instance_config().is_none());
assert!(x.http_config().is_none());Sourcepub fn secure_source_manager_instance_config(
&self,
) -> Option<&Box<SecureSourceManagerInstanceConfig>>
pub fn secure_source_manager_instance_config( &self, ) -> Option<&Box<SecureSourceManagerInstanceConfig>>
The value of connection_config
if it holds a SecureSourceManagerInstanceConfig, None if the field is not set or
holds a different branch.
Sourcepub fn set_secure_source_manager_instance_config<T: Into<Box<SecureSourceManagerInstanceConfig>>>(
self,
v: T,
) -> Self
pub fn set_secure_source_manager_instance_config<T: Into<Box<SecureSourceManagerInstanceConfig>>>( self, v: T, ) -> Self
Sets the value of connection_config
to hold a SecureSourceManagerInstanceConfig.
Note that all the setters affecting connection_config are
mutually exclusive.
§Example
use google_cloud_developerconnect_v1::model::SecureSourceManagerInstanceConfig;
let x = Connection::new().set_secure_source_manager_instance_config(SecureSourceManagerInstanceConfig::default()/* use setters */);
assert!(x.secure_source_manager_instance_config().is_some());
assert!(x.github_config().is_none());
assert!(x.github_enterprise_config().is_none());
assert!(x.gitlab_config().is_none());
assert!(x.gitlab_enterprise_config().is_none());
assert!(x.bitbucket_data_center_config().is_none());
assert!(x.bitbucket_cloud_config().is_none());
assert!(x.http_config().is_none());Sourcepub fn http_config(&self) -> Option<&Box<GenericHTTPEndpointConfig>>
pub fn http_config(&self) -> Option<&Box<GenericHTTPEndpointConfig>>
The value of connection_config
if it holds a HttpConfig, None if the field is not set or
holds a different branch.
Sourcepub fn set_http_config<T: Into<Box<GenericHTTPEndpointConfig>>>(
self,
v: T,
) -> Self
pub fn set_http_config<T: Into<Box<GenericHTTPEndpointConfig>>>( self, v: T, ) -> Self
Sets the value of connection_config
to hold a HttpConfig.
Note that all the setters affecting connection_config are
mutually exclusive.
§Example
use google_cloud_developerconnect_v1::model::GenericHTTPEndpointConfig;
let x = Connection::new().set_http_config(GenericHTTPEndpointConfig::default()/* use setters */);
assert!(x.http_config().is_some());
assert!(x.github_config().is_none());
assert!(x.github_enterprise_config().is_none());
assert!(x.gitlab_config().is_none());
assert!(x.gitlab_enterprise_config().is_none());
assert!(x.bitbucket_data_center_config().is_none());
assert!(x.bitbucket_cloud_config().is_none());
assert!(x.secure_source_manager_instance_config().is_none());Trait Implementations§
Source§impl Clone for Connection
impl Clone for Connection
Source§fn clone(&self) -> Connection
fn clone(&self) -> Connection
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for Connection
impl Debug for Connection
Source§impl Default for Connection
impl Default for Connection
Source§fn default() -> Connection
fn default() -> Connection
Source§impl PartialEq for Connection
impl PartialEq for Connection
impl StructuralPartialEq for Connection
Auto Trait Implementations§
impl Freeze for Connection
impl RefUnwindSafe for Connection
impl Send for Connection
impl Sync for Connection
impl Unpin for Connection
impl UnsafeUnpin for Connection
impl UnwindSafe for Connection
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<T> FutureExt for T
impl<T> FutureExt for T
Source§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
Source§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
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> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request