Replaces an existing route within a route table in a VPC. For more information about route tables, go to Route Tables in the Amazon Virtual Private Cloud User Guide.
Access
public
Parameters
Parameter |
Type |
Required |
Description |
---|---|---|---|
|
Required |
The ID of the route table where the route will be replaced. |
|
|
Required |
The CIDR address block used for the destination match. For example: |
|
|
Optional |
An associative array of parameters that can have the following keys:
|
Returns
Type |
Description |
---|---|
A |
Examples
Replace an existing VPC route.
$ec2 = new AmazonEC2(); $response = $ec2->replace_route('rtb-e68b0b8f', '0.0.0.0/0', array( 'GatewayId' => 'igw-8c8e0ee5' )); var_dump($response->isOK());Result:
bool(true)
Related Methods
Source
Method defined in services/ec2.class.php | Toggle source view (8 lines) | View on GitHub