Class: LambdaWrap::AwsService Abstract

Inherits:
Object
  • Object
show all
Defined in:
lib/lambda_wrap/aws_service.rb

Overview

This class is abstract.

Super Abstract Class for all AWS services and their calls.

Since:

  • 1.0

Direct Known Subclasses

ApiGateway, DynamoTable, Lambda

Instance Method Summary collapse

Instance Method Details

#delete(client, region = 'AWS_REGION') ⇒ Object

Since:

  • 1.0



24
25
26
27
28
# File 'lib/lambda_wrap/aws_service.rb', line 24

def delete(client, region = 'AWS_REGION')
  @client = client
  @region = region
  client_guard
end

#deploy(environment, client, region = 'AWS_REGION') ⇒ Object

Since:

  • 1.0



6
7
8
9
10
11
12
13
# File 'lib/lambda_wrap/aws_service.rb', line 6

def deploy(environment, client, region = 'AWS_REGION')
  unless environment.is_a?(LambdaWrap::Environment)
    raise ArgumentError, 'Must pass a LambdaWrap::Environment class.'
  end
  @client = client
  @region = region
  client_guard
end

#teardown(environment, client, region = 'AWS_REGION') ⇒ Object

Since:

  • 1.0



15
16
17
18
19
20
21
22
# File 'lib/lambda_wrap/aws_service.rb', line 15

def teardown(environment, client, region = 'AWS_REGION')
  unless environment.is_a?(LambdaWrap::Environment)
    raise ArgumentError, 'Must pass a LambdaWrap::Environment class.'
  end
  @client = client
  @region = region
  client_guard
end