Class: AWS::EC2::VPNGateway::Attachment
- Inherits:
-
Object
- Object
- AWS::EC2::VPNGateway::Attachment
- Defined in:
- lib/aws/ec2/vpn_gateway/attachment.rb
Instance Attribute Summary collapse
- #state ⇒ Symbol readonly
- #vpc ⇒ VPC readonly
- #vpn_gateway ⇒ VPNGateway readonly
Instance Method Summary collapse
-
#delete ⇒ nil
(also: #detach)
Deletes this attachment.
-
#initialize(vpn_gateway, details) ⇒ Attachment
constructor
A new instance of Attachment.
Constructor Details
#initialize(vpn_gateway, details) ⇒ Attachment
Returns a new instance of Attachment.
20 21 22 23 24 |
# File 'lib/aws/ec2/vpn_gateway/attachment.rb', line 20 def initialize vpn_gateway, details @vpn_gateway = vpn_gateway @vpc = VPC.new(details.vpc_id, :config => vpn_gateway.config) @state = details.state.to_sym end |
Instance Attribute Details
#state ⇒ Symbol (readonly)
33 34 35 |
# File 'lib/aws/ec2/vpn_gateway/attachment.rb', line 33 def state @state end |
#vpc ⇒ VPC (readonly)
30 31 32 |
# File 'lib/aws/ec2/vpn_gateway/attachment.rb', line 30 def vpc @vpc end |
#vpn_gateway ⇒ VPNGateway (readonly)
27 28 29 |
# File 'lib/aws/ec2/vpn_gateway/attachment.rb', line 27 def vpn_gateway @vpn_gateway end |
Instance Method Details
#delete ⇒ nil Also known as: detach
Deletes this attachment.
37 38 39 |
# File 'lib/aws/ec2/vpn_gateway/attachment.rb', line 37 def delete vpn_gateway.detach(vpc) end |