class AWS::EC2::RouteTable::Route

def delete

Returns:
  • (nil) -
def delete
  route_table.delete_route(destination_cidr_block)
end

def initialize route_table, details

def initialize route_table, details
  @route_table = route_table
  @destination_cidr_block = details.destination_cidr_block
  if details[:gateway_id]
    @internet_gateway = InternetGateway.new(
      details[:gateway_id],
      :config => route_table.config)
  end
  if details[:instance_id]
    @instance = Instance.new(details[:instance_id],
      :vpc_id => route_table.vpc_id,
      :owner_id => details[:instance_owner_id],
      :config => route_table.config)
  end
  if details[:network_interface_id]
    @network_interface = NetworkInterface.new(
      details[:network_interface_id],
      :vpc_id => route_table.vpc_id,
      :config => route_table.config)
  end
  @target = (internet_gateway || instance || network_interface)
  @origin = { 'CreateRoute' => :create_route, 'CreateRouteTable' => :create_route_table, 'EnableVgwRoutePropagation' => :enable_vgw_route_propagation }[details.origin]
  @state = details.state.to_sym
end

def replace options = {}

Returns:
  • (nil) -

Options Hash: (**options)
  • :network_interface (NetworkInterface, String) --
  • :instance (Instance, String) -- An instance (object
  • :gateway (Gateway, String) -- A gateway (object or

Parameters:
  • options (Hash) --
def replace options = {}
  route_table.replace_route(destination_cidr_block, options)
end