[−][src]Struct aws_arn::ARN
Amazon Resource Names (ARNs) uniquely identify AWS resources. We require an ARN when you need to specify a resource unambiguously across all of AWS, such as in IAM policies, Amazon Relational Database Service (Amazon RDS) tags, and API calls.
The following are the general formats for ARNs; the specific components and values used depend on the AWS service.
arn:partition:service:region:account-id:resource-id
arn:partition:service:region:account-id:resource-type/resource-id
arn:partition:service:region:account-id:resource-type:resource-id
From ARN Format
Fields
partition: Option<String>The partition that the resource is in. For standard AWS Regions, the partition is aws.
If you have resources in other partitions, the partition is aws-partitionname. For
example, the partition for resources in the China (Beijing) Region is aws-cn.
service: StringThe service namespace that identifies the AWS product (for example, Amazon S3, IAM, or Amazon RDS).
region: Option<String>The Region that the resource resides in. The ARNs for some resources do not require a Region, so this component might be omitted.
account_id: Option<String>The ID of the AWS account that owns the resource, without the hyphens. For example,
123456789012. The ARNs for some resources don't require an account number, so this
component might be omitted.
resource: ResourceThe content of this part of the ARN varies by service. A resource identifier can
be the name or ID of the resource (for example, user/Bob or
instance/i-1234567890abcdef0) or a resource path. For example, some resource
identifiers include a parent resource
(sub-resource-type/parent-resource/sub-resource) or a qualifier such as a
version (resource-type:resource-name:qualifier).
Methods
impl ARN[src]
pub fn validate(&self) -> Result<(), ArnError>[src]
Validate this ARN, if provided the validators struct will be used to also
provide any service-specific validation.
Trait Implementations
Auto Trait Implementations
impl Send for ARN
impl Sync for ARN
impl Unpin for ARN
impl UnwindSafe for ARN
impl RefUnwindSafe for ARN
Blanket Implementations
impl<T, U> Into<U> for T where
U: From<T>, [src]
U: From<T>,
impl<T> From<T> for T[src]
impl<T> ToOwned for T where
T: Clone, [src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T[src]
fn clone_into(&self, target: &mut T)[src]
impl<T> ToString for T where
T: Display + ?Sized, [src]
T: Display + ?Sized,
impl<T, U> TryFrom<U> for T where
U: Into<T>, [src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>, [src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>[src]
impl<T> Borrow<T> for T where
T: ?Sized, [src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized, [src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T[src]
impl<T> Any for T where
T: 'static + ?Sized, [src]
T: 'static + ?Sized,