|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jboss.resteasy.test.TestPortProvider
public class TestPortProvider
Utility class that provides a port number for the Resteasy embedded container.
Constructor Summary | |
---|---|
TestPortProvider()
|
Method Summary | ||
---|---|---|
static ClientRequest |
createClientRequest(ClientRequestFactory factory,
String path)
|
|
static ClientRequest |
createClientRequest(String path)
Create a Resteasy ClientRequest object using the configured port. |
|
static
|
createProxy(Class<T> clazz)
Create a Resteasy client proxy with an empty base request path. |
|
static
|
createProxy(Class<T> clazz,
String path)
Create a Resteasy client proxy. |
|
static URI |
createURI(String path)
Create a URI for the provided path, using the configured port |
|
static URL |
createURL(String path)
Create a URL for the provided path, using the configured port |
|
static String |
generateBaseUrl()
Generate a base URL incorporating the configured port. |
|
static String |
generateURL(String path)
Generate a URL incorporating the configured port. |
|
static int |
getPort()
Look up the configured port number, first checking an environment variable (RESTEASY_PORT), then a system property (org.jboss.resteasy.port), and finally the default port (8081). |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public TestPortProvider()
Method Detail |
---|
public static ClientRequest createClientRequest(String path)
path
- the request path
public static ClientRequest createClientRequest(ClientRequestFactory factory, String path)
public static <T> T createProxy(Class<T> clazz)
clazz
- the client interface class
public static <T> T createProxy(Class<T> clazz, String path)
clazz
- the client interface class
public static URI createURI(String path)
path
- the request path
public static URL createURL(String path) throws MalformedURLException
path
- the request path
MalformedURLException
public static String generateBaseUrl()
public static String generateURL(String path)
path
- the path
public static int getPort()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |