public Ec2Metadata getEc2() {
        return this.ec2;
    }
<p>
An object that contains metadata details for an Amazon EC2 instance.
</p>

@return An object that contains metadata details for an Amazon EC2 instance.
aws-java-sdk-inspector2/src/main/java/com/amazonaws/services/inspector2/model/ResourceScanMetadata.java