public static <T> String credentialTypeOf(T input) { Class<?> authenticationType = input.getClass(); checkArgument(authenticationType.isAnnotationPresent(CredentialType.class), "programming error: %s should have annotation %s", authenticationType, CredentialType.class.getName()); return authenticationType.getAnnotation(CredentialType.class).value(); }
public static <T> String credentialTypeOf(T input) { Class<?> authenticationType = input.getClass(); checkArgument(authenticationType.isAnnotationPresent(CredentialType.class), "programming error: %s should have annotation %s", authenticationType, CredentialType.class.getName()); return authenticationType.getAnnotation(CredentialType.class).value(); }
public static <T> String credentialTypeOf(T input) { Class<?> authenticationType = input.getClass(); checkArgument(authenticationType.isAnnotationPresent(CredentialType.class), "programming error: %s should have annotation %s", authenticationType, CredentialType.class.getName()); return authenticationType.getAnnotation(CredentialType.class).value(); }
public static <T> String credentialTypeOf(T input) { Class<?> authenticationType = input.getClass(); checkArgument(authenticationType.isAnnotationPresent(CredentialType.class), "programming error: %s should have annotation %s", authenticationType, CredentialType.class.getName()); return authenticationType.getAnnotation(CredentialType.class).value(); }
protected void addCredentialsInArgsOrNull(GeneratedHttpRequest gRequest, Builder<String, Object> builder) { for (Object arg : Iterables.filter(gRequest.getInvocation().getArgs(), Predicates.notNull())) { if (arg.getClass().isAnnotationPresent(CredentialType.class)) { builder.put(arg.getClass().getAnnotation(CredentialType.class).value(), arg); } } }
protected void addCredentialsInArgsOrNull(GeneratedHttpRequest gRequest, Builder<String, Object> builder) { for (Object arg : Iterables.filter(gRequest.getInvocation().getArgs(), Predicates.notNull())) { if (arg.getClass().isAnnotationPresent(CredentialType.class)) { builder.put(arg.getClass().getAnnotation(CredentialType.class).value(), arg); } } }
protected void addCredentialsInArgsOrNull(GeneratedHttpRequest gRequest, Builder<String, Object> builder) { for (Object arg : Iterables.filter(gRequest.getInvocation().getArgs(), Predicates.notNull())) { if (arg.getClass().isAnnotationPresent(CredentialType.class)) { builder.put(arg.getClass().getAnnotation(CredentialType.class).value(), arg); } } }
protected void addCredentialsInArgsOrNull(GeneratedHttpRequest gRequest, Builder<String, Object> builder) { for (Object arg : Iterables.filter(gRequest.getInvocation().getArgs(), Predicates.notNull())) { if (arg.getClass().isAnnotationPresent(CredentialType.class)) { builder.put(arg.getClass().getAnnotation(CredentialType.class).value(), arg); } } }
public static <T> String credentialTypeOf(T input) { return credentialTypeObjectOf(input).value(); }
protected void addCredentialsInArgsOrNull(GeneratedHttpRequest gRequest, Builder<String, Object> builder) { for (Object arg : Iterables.filter(gRequest.getInvocation().getArgs(), Predicates.notNull())) { if (arg.getClass().isAnnotationPresent(CredentialType.class)) { builder.put(arg.getClass().getAnnotation(CredentialType.class).value(), arg); } } }