com.google.api.services.compute.model.Subnetwork

Here are the examples of the java api class com.google.api.services.compute.model.Subnetwork taken from open source projects.

1. SubnetworkInfo#toPb()

Project: gcloud-java
Source File: SubnetworkInfo.java
View license
Subnetwork toPb() {
    Subnetwork subnetworkPb = new Subnetwork();
    if (generatedId != null) {
        subnetworkPb.setId(new BigInteger(generatedId));
    }
    if (creationTimestamp != null) {
        subnetworkPb.setCreationTimestamp(TIMESTAMP_FORMATTER.print(creationTimestamp));
    }
    subnetworkPb.setName(subnetworkId.subnetwork());
    subnetworkPb.setDescription(description);
    subnetworkPb.setSelfLink(subnetworkId.selfLink());
    subnetworkPb.setGatewayAddress(gatewayAddress);
    subnetworkPb.setNetwork(network.selfLink());
    subnetworkPb.setIpCidrRange(ipRange);
    return subnetworkPb;
}