use of com.google.api.server.spi.config.Named in project endpoints-java by cloudendpoints.
the class ServletRequestParamReaderTest method testReadEnumCollectionParameters.
@Test
public void testReadEnumCollectionParameters() throws Exception {
class Test {
@SuppressWarnings("unused")
public void collection(@Named("collection") Collection<Outcome> outcomes) {
}
}
Method method = Test.class.getDeclaredMethod("collection", Collection.class);
doTestReadCollectionEnumParameter("collection", EndpointMethod.create(Test.class, method));
}
use of com.google.api.server.spi.config.Named in project endpoints-java by cloudendpoints.
the class ServletRequestParamReaderTest method testReadDateArrayParameters.
@Test
public void testReadDateArrayParameters() throws Exception {
class Test {
@SuppressWarnings("unused")
public void array(@Named("array") Date[] dates) {
}
}
Method method = Test.class.getDeclaredMethod("array", Date[].class);
doTestReadArrayDateParameter("array", EndpointMethod.create(Test.class, method));
}
use of com.google.api.server.spi.config.Named in project endpoints-java by cloudendpoints.
the class ServletRequestParamReaderTest method testReadSetParameters.
@Test
public void testReadSetParameters() throws Exception {
class Test {
@SuppressWarnings("unused")
public void collection(@Named("set") Set<Integer> integers) {
}
}
Method method = Test.class.getDeclaredMethod("collection", Set.class);
doTestSetParameter("set", EndpointMethod.create(Test.class, method));
}
use of com.google.api.server.spi.config.Named in project endpoints-java by cloudendpoints.
the class ServletRequestParamReaderTest method testReadArrayParameters.
@Test
public void testReadArrayParameters() throws Exception {
class Test {
@SuppressWarnings("unused")
public void array(@Named("array") Integer[] integers) {
}
}
Method method = Test.class.getDeclaredMethod("array", Integer[].class);
doTestReadArrayParameter("array", EndpointMethod.create(Test.class, method));
}
use of com.google.api.server.spi.config.Named in project endpoints-java by cloudendpoints.
the class ServletRequestParamReaderTest method testReadListParameters.
@Test
public void testReadListParameters() throws Exception {
class Test {
@SuppressWarnings("unused")
public void collection(@Named("list") List<Integer> integers) {
}
}
Method method = Test.class.getDeclaredMethod("collection", List.class);
doTestCollectionParameter("list", EndpointMethod.create(Test.class, method));
}
Aggregations