Class IpWhitelist.CreateCallBuilder

java.lang.Object
com.ngrok.services.IpWhitelist.CreateCallBuilder
Enclosing class:
IpWhitelist

public class IpWhitelist.CreateCallBuilder extends Object
A builder object encapsulating state for an unsent Create API call.
  • Method Details

    • description

      public IpWhitelist.CreateCallBuilder description(String description)
      human-readable description of the source IPs for this IP whitelist entry. optional, max 255 bytes.
      Parameters:
      description - the value of the description parameter as a String
      Returns:
      the call builder instance
    • description

      public IpWhitelist.CreateCallBuilder description(Optional<String> description)
      human-readable description of the source IPs for this IP whitelist entry. optional, max 255 bytes.
      Parameters:
      description - the value of the description parameter as an Optional of String
      Returns:
      the call builder instance
    • metadata

      public IpWhitelist.CreateCallBuilder metadata(String metadata)
      arbitrary user-defined machine-readable data of this IP whitelist entry. optional, max 4096 bytes.
      Parameters:
      metadata - the value of the metadata parameter as a String
      Returns:
      the call builder instance
    • metadata

      public IpWhitelist.CreateCallBuilder metadata(Optional<String> metadata)
      arbitrary user-defined machine-readable data of this IP whitelist entry. optional, max 4096 bytes.
      Parameters:
      metadata - the value of the metadata parameter as an Optional of String
      Returns:
      the call builder instance
    • ipNet

      public IpWhitelist.CreateCallBuilder ipNet(String ipNet)
      an IP address or IP network range in CIDR notation (e.g. 10.1.1.1 or 10.1.0.0/16) of addresses that will be whitelisted to communicate with your tunnel endpoints
      Parameters:
      ipNet - the value of the ip_net parameter as a String
      Returns:
      the call builder instance
    • ipNet

      public IpWhitelist.CreateCallBuilder ipNet(Optional<String> ipNet)
      an IP address or IP network range in CIDR notation (e.g. 10.1.1.1 or 10.1.0.0/16) of addresses that will be whitelisted to communicate with your tunnel endpoints
      Parameters:
      ipNet - the value of the ip_net parameter as an Optional of String
      Returns:
      the call builder instance
    • call

      Initiates the API call asynchronously.
      Returns:
      a CompletionStage of IpWhitelistEntry
    • blockingCall

      public IpWhitelistEntry blockingCall() throws InterruptedException
      Initiates the API call and blocks until it returns.
      Returns:
      IpWhitelistEntry
      Throws:
      InterruptedException - if the thread was interrupted during the call