cfdsl.fn.AvailabilityZones Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of cfdsl Show documentation
Show all versions of cfdsl Show documentation
Java DSL for Amazon CloudFormation templates
The newest version!
package cfdsl.fn;
import cfdsl.ec2.property.Region;
import com.google.common.collect.ImmutableMap;
public final class AvailabilityZones implements StringLike {
private static final AvailabilityZones FOR_CURRENT_REGION = new AvailabilityZones("");
private final String region;
private AvailabilityZones(String region) {
this.region = region;
}
public static AvailabilityZones forRegion(Region region) {
return new AvailabilityZones(region.toString());
}
public static AvailabilityZones forCurrentRegion() {
return FOR_CURRENT_REGION;
}
@Override
public ImmutableMap getMap() {
return ImmutableMap.of("Fn::GetAZs", region);
}
}