public static class

PortForwardingRule.Builder

extends Object
java.lang.Object
   ↳ android.support.test.rule.PortForwardingRule.Builder

Summary

Public Constructors
PortForwardingRule.Builder()
Public Methods
PortForwardingRule build()
PortForwardingRule.Builder withProperties(Properties properties)
Builder which allows to pass a Properties object for testing.
PortForwardingRule.Builder withProxyHost(String proxyHost)
Builder to set a specific host address to forward the network traffic to.
PortForwardingRule.Builder withProxyPort(int proxyPort)
Builder to set a specific port number to forward the network traffic to.
[Expand]
Inherited Methods
From class java.lang.Object

Public Constructors

public PortForwardingRule.Builder ()

Public Methods

public PortForwardingRule build ()

public PortForwardingRule.Builder withProperties (Properties properties)

Builder which allows to pass a Properties object for testing. This will help to avoid the system properties being affected by tests.

Parameters
properties Properties: A pre-constructed properties object for testing.
Returns
PortForwardingRule.Builder

public PortForwardingRule.Builder withProxyHost (String proxyHost)

Builder to set a specific host address to forward the network traffic to.

Parameters
proxyHost String: The host address to which the network traffic is forwarded during tests.
Returns
PortForwardingRule.Builder

public PortForwardingRule.Builder withProxyPort (int proxyPort)

Builder to set a specific port number to forward the network traffic to.

Parameters
proxyPort int: The port number to which the network traffic is forwarded during tests.
Returns
PortForwardingRule.Builder