@DataProvider(name = com.linkedin.restli.internal.common.TestConstants.RESTLI_PROTOCOL_1_2_PREFIX + "newBuildersClientDataDataProvider")
public Object[][] newBuildersClientDataDataProvider()
{
return new Object[][]
{
{ new RestClient(CLIENT, URI_PREFIX), "application/json", new GreetingsRequestBuilders() }, // default client
{ new RestClient(CLIENT, URI_PREFIX), "application/json", new GreetingsRequestBuilders(TestConstants.FORCE_USE_NEXT_OPTIONS) }, // default client
{
new RestClient(CLIENT,
URI_PREFIX,
Collections.singletonList(RestClient.AcceptType.PSON)),
"application/x-pson",
new GreetingsRequestBuilders()
},
{
new RestClient(CLIENT,
URI_PREFIX,
Collections.singletonList(RestClient.AcceptType.PSON)),
"application/x-pson",
new GreetingsRequestBuilders(TestConstants.FORCE_USE_NEXT_OPTIONS)
},
{
new RestClient(CLIENT,
URI_PREFIX,
Collections.singletonList(RestClient.AcceptType.PSON)),
"application/x-pson",
new GreetingsRequestBuilders(TestConstants.FORCE_USE_NEXT_OPTIONS)
},
{
new RestClient(CLIENT,
URI_PREFIX,
Collections.singletonList(RestClient.AcceptType.JSON)),
"application/json",
new GreetingsRequestBuilders()
},
{
new RestClient(CLIENT,
URI_PREFIX,
Collections.singletonList(RestClient.AcceptType.JSON)),
"application/json",
new GreetingsRequestBuilders(TestConstants.FORCE_USE_NEXT_OPTIONS)
},
{
new RestClient(CLIENT, URI_PREFIX,
Collections.singletonList(
RestClient.AcceptType.ANY)),
"application/json",
new GreetingsRequestBuilders()
},
{
new RestClient(CLIENT, URI_PREFIX,
Collections.singletonList(
RestClient.AcceptType.ANY)),
"application/json",
new GreetingsRequestBuilders(TestConstants.FORCE_USE_NEXT_OPTIONS)
},
{
new RestClient(CLIENT,
URI_PREFIX,
Arrays.asList(RestClient.AcceptType.PSON, RestClient.AcceptType.JSON)),
"application/x-pson",
new GreetingsRequestBuilders()
},
{
new RestClient(CLIENT,
URI_PREFIX,
Arrays.asList(RestClient.AcceptType.PSON, RestClient.AcceptType.JSON)),
"application/x-pson",
new GreetingsRequestBuilders(TestConstants.FORCE_USE_NEXT_OPTIONS)
},
{
new RestClient(CLIENT,
URI_PREFIX,
Arrays.asList(RestClient.AcceptType.JSON,RestClient.AcceptType.PSON)),
"application/json",
new GreetingsRequestBuilders()
},
{
new RestClient(CLIENT,
URI_PREFIX,
Arrays.asList(RestClient.AcceptType.JSON,RestClient.AcceptType.PSON)),
"application/json",
new GreetingsRequestBuilders(TestConstants.FORCE_USE_NEXT_OPTIONS)
},
{
new RestClient(CLIENT,
URI_PREFIX,
Arrays.asList(RestClient.AcceptType.PSON, RestClient.AcceptType.ANY)),
"application/x-pson",
new GreetingsRequestBuilders()
},
{
new RestClient(CLIENT,
URI_PREFIX,
Arrays.asList(RestClient.AcceptType.PSON, RestClient.AcceptType.ANY)),
"application/x-pson",
new GreetingsRequestBuilders(TestConstants.FORCE_USE_NEXT_OPTIONS)
},
{
new RestClient(CLIENT,
URI_PREFIX,
Arrays.asList(RestClient.AcceptType.JSON, RestClient.AcceptType.ANY)),
"application/json",
new GreetingsRequestBuilders()
},
{
new RestClient(CLIENT,
URI_PREFIX,
Arrays.asList(RestClient.AcceptType.JSON, RestClient.AcceptType.ANY)),
"application/json",
new GreetingsRequestBuilders(TestConstants.FORCE_USE_NEXT_OPTIONS)
},
{
new RestClient(CLIENT,
URI_PREFIX,
Arrays.asList(RestClient.AcceptType.ANY, RestClient.AcceptType.PSON)),
"application/x-pson",
new GreetingsRequestBuilders()
},
{
new RestClient(CLIENT,
URI_PREFIX,
Arrays.asList(RestClient.AcceptType.ANY, RestClient.AcceptType.PSON)),
"application/x-pson",
new GreetingsRequestBuilders(TestConstants.FORCE_USE_NEXT_OPTIONS)
},
{
new RestClient(CLIENT,
URI_PREFIX,
Arrays.asList(RestClient.AcceptType.ANY, RestClient.AcceptType.JSON)),
"application/json",
new GreetingsRequestBuilders()
},
{
new RestClient(CLIENT,
URI_PREFIX,
Arrays.asList(RestClient.AcceptType.ANY, RestClient.AcceptType.JSON)),
"application/json",
new GreetingsRequestBuilders(TestConstants.FORCE_USE_NEXT_OPTIONS)
},
// accept types and content types
{
new RestClient(CLIENT,
URI_PREFIX,
RestClient.ContentType.JSON, Collections.<RestClient.AcceptType>emptyList()),
"application/json",
new GreetingsRequestBuilders()
},
{
new RestClient(CLIENT,
URI_PREFIX,
RestClient.ContentType.JSON, Collections.<RestClient.AcceptType>emptyList()),
"application/json",
new GreetingsRequestBuilders(TestConstants.FORCE_USE_NEXT_OPTIONS)
},
{
new RestClient(CLIENT,
URI_PREFIX,
RestClient.ContentType.JSON, Collections.singletonList(RestClient.AcceptType.JSON)),
"application/json",
new GreetingsRequestBuilders()
},
{
new RestClient(CLIENT,
URI_PREFIX,
RestClient.ContentType.JSON, Collections.singletonList(RestClient.AcceptType.JSON)),
"application/json",
new GreetingsRequestBuilders(TestConstants.FORCE_USE_NEXT_OPTIONS)
},
{
new RestClient(CLIENT,
URI_PREFIX,
RestClient.ContentType.JSON, Collections.singletonList(RestClient.AcceptType.PSON)),
"application/x-pson",
new GreetingsRequestBuilders()
},
{
new RestClient(CLIENT,
URI_PREFIX,
RestClient.ContentType.JSON, Collections.singletonList(RestClient.AcceptType.PSON)),
"application/x-pson",
new GreetingsRequestBuilders(TestConstants.FORCE_USE_NEXT_OPTIONS)
},
{
new RestClient(CLIENT,
URI_PREFIX,
RestClient.ContentType.PSON, Collections.<RestClient.AcceptType>emptyList()),
"application/json",
new GreetingsRequestBuilders()
},
{
new RestClient(CLIENT,
URI_PREFIX,
RestClient.ContentType.PSON, Collections.<RestClient.AcceptType>emptyList()),
"application/json",
new GreetingsRequestBuilders(TestConstants.FORCE_USE_NEXT_OPTIONS)
},
{
new RestClient(CLIENT,
URI_PREFIX,
RestClient.ContentType.PSON, Collections.singletonList(RestClient.AcceptType.JSON)),
"application/json",
new GreetingsRequestBuilders()
},
{
new RestClient(CLIENT,
URI_PREFIX,
RestClient.ContentType.PSON, Collections.singletonList(RestClient.AcceptType.JSON)),
"application/json",
new GreetingsRequestBuilders(TestConstants.FORCE_USE_NEXT_OPTIONS)
},
{
new RestClient(CLIENT,
URI_PREFIX,
RestClient.ContentType.PSON, Collections.singletonList(RestClient.AcceptType.PSON)),
"application/x-pson",
new GreetingsRequestBuilders()
},
{
new RestClient(CLIENT,
URI_PREFIX,
RestClient.ContentType.PSON, Collections.singletonList(RestClient.AcceptType.PSON)),
"application/x-pson",
new GreetingsRequestBuilders(TestConstants.FORCE_USE_NEXT_OPTIONS)
}