List of usage examples for com.amazonaws.services.ec2.model Vpc getTags
public java.util.List<Tag> getTags()
Any tags assigned to the VPC.
From source file:com.infinitechaos.vpcviewer.web.rest.dto.VpcDTO.java
License:Open Source License
public VpcDTO(final Vpc vpc) { this.vpcId = vpc.getVpcId(); this.cidrBlock = vpc.getCidrBlock(); this.state = vpc.getState(); this.tags.addAll(vpc.getTags().stream().map(TagDTO::new).collect(Collectors.toList())); this.name = vpc.getTags().stream().filter(t -> t.getKey().equals("Name")).findFirst().map(Tag::getValue) .orElse("n/a"); }