pub struct Company {Show 14 fields
pub name: String,
pub company_id: i64,
pub display_name: String,
pub type: i32,
pub address: String,
pub email: String,
pub fax: String,
pub phone: String,
pub external_id: String,
pub comment: String,
pub credit_status: i32,
pub applied_labels: Vec<AppliedLabel>,
pub primary_contact: Option<String>,
pub applied_teams: Vec<String>,
}
Expand description
The Company
resource.
Fields§
§name: String
Identifier. The resource name of the Company
.
Format: networks/{network_code}/companies/{company_id}
company_id: i64
Output only. Company
ID.
display_name: String
Required. The display name of the Company
.
This value has a maximum length of 127 characters.
type: i32
Required. The type of the Company
.
address: String
Optional. The address for the Company
.
This value has a maximum length of 1024 characters.
email: String
Optional. The email for the Company
.
This value has a maximum length of 128 characters.
fax: String
Optional. The fax number for the Company
.
This value has a maximum length of 63 characters.
phone: String
Optional. The phone number for the Company
.
This value has a maximum length of 63 characters.
external_id: String
Optional. The external ID for the Company
.
This value has a maximum length of 255 characters.
comment: String
Optional. Comments about the Company
.
This value has a maximum length of 1024 characters.
credit_status: i32
Optional. The credit status of this company.
This attribute defaults to ACTIVE
if basic settings are enabled and
ON_HOLD
if advance settings are enabled.
applied_labels: Vec<AppliedLabel>
Optional. The labels that are directly applied to this company.
primary_contact: Option<String>
Optional. The resource names of primary Contact of this company. Format: “networks/{network_code}/contacts/{contact_id}”
applied_teams: Vec<String>
Optional. The resource names of Teams that are directly associated with this company. Format: “networks/{network_code}/teams/{team_id}”
Implementations§
source§impl Company
impl Company
sourcepub fn type(&self) -> CompanyType
pub fn type(&self) -> CompanyType
Returns the enum value of type
, or the default if the field is set to an invalid enum value.
sourcepub fn set_type(&mut self, value: CompanyType)
pub fn set_type(&mut self, value: CompanyType)
Sets type
to the provided enum value.
sourcepub fn credit_status(&self) -> CompanyCreditStatus
pub fn credit_status(&self) -> CompanyCreditStatus
Returns the enum value of credit_status
, or the default if the field is set to an invalid enum value.
sourcepub fn set_credit_status(&mut self, value: CompanyCreditStatus)
pub fn set_credit_status(&mut self, value: CompanyCreditStatus)
Sets credit_status
to the provided enum value.
sourcepub fn primary_contact(&self) -> &str
pub fn primary_contact(&self) -> &str
Returns the value of primary_contact
, or the default value if primary_contact
is unset.
Trait Implementations§
source§impl Message for Company
impl Message for Company
source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
source§fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
source§fn encode_to_vec(&self) -> Vec<u8>where
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8>where
Self: Sized,
source§fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
source§fn encode_length_delimited_to_vec(&self) -> Vec<u8>where
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8>where
Self: Sized,
source§fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
source§fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
source§fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self
. Read moresource§fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self
.source§impl PartialEq for Company
impl PartialEq for Company
impl StructuralPartialEq for Company
Auto Trait Implementations§
impl Freeze for Company
impl RefUnwindSafe for Company
impl Send for Company
impl Sync for Company
impl Unpin for Company
impl UnwindSafe for Company
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<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§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