@Test public void testProfileProviderWithOneArg() { AWSCredentialsProvider provider = decoder.decodeValue(credentialName2 + "|arg"); assertThat(provider, hasCredentials("arg", "blank")); }
@Override public AWSCredentialsProvider decodeValue(String value) { if (value != null) { List<String> providerNames = getProviderNames(value); List<AWSCredentialsProvider> providers = getValidCredentialsProviders(providerNames); AWSCredentialsProvider[] ps = new AWSCredentialsProvider[providers.size()]; providers.toArray(ps); return new AWSCredentialsProviderChain(providers); } else { throw new IllegalArgumentException("Property AWSCredentialsProvider is missing."); } }
AWSCredentialsProviderPropertyValueDecoder implements IPropertyValueDecoder<AWSCredentialsProvider> { @Override public AWSCredentialsProvider decodeValue(String value) { if (value != null) { List<String> providerNames = getProviderNames(value); List<AWSCredentialsProvider> providers = getValidCredentialsProviders(providerNames); AWSCredentialsProvider[] ps = new AWSCredentialsProvider[providers.size()]; providers.toArray(ps); return new AWSCredentialsProviderChain(providers); } else { throw new IllegalArgumentException("Property AWSCredentialsProvider is missing."); } } }
AWSCredentialsProviderPropertyValueDecoder implements IPropertyValueDecoder<AWSCredentialsProvider> { @Override public AWSCredentialsProvider decodeValue(String value) { if (value != null) { List<String> providerNames = getProviderNames(value); List<AWSCredentialsProvider> providers = getValidCredentialsProviders(providerNames); AWSCredentialsProvider[] ps = new AWSCredentialsProvider[providers.size()]; providers.toArray(ps); return new AWSCredentialsProviderChain(providers); } else { throw new IllegalArgumentException("Property AWSCredentialsProvider is missing."); } } AWSCredentialsProviderPropertyValueDecoder(); }
AWSCredentialsProviderPropertyValueDecoder implements IPropertyValueDecoder<AWSCredentialsProvider> { @Override public AWSCredentialsProvider decodeValue(String value) { if (value != null) { List<String> providerNames = getProviderNames(value); List<AWSCredentialsProvider> providers = getValidCredentialsProviders(providerNames); AWSCredentialsProvider[] ps = new AWSCredentialsProvider[providers.size()]; providers.toArray(ps); return new AWSCredentialsProviderChain(providers); } else { throw new IllegalArgumentException("Property AWSCredentialsProvider is missing."); } } AWSCredentialsProviderPropertyValueDecoder(); @Override AWSCredentialsProvider decodeValue(String value); @Override List<Class<AWSCredentialsProvider>> getSupportedTypes(); }
AWSCredentialsProviderPropertyValueDecoder implements IPropertyValueDecoder<AWSCredentialsProvider> { @Override public AWSCredentialsProvider decodeValue(String value) { if (value != null) { List<String> providerNames = getProviderNames(value); List<AWSCredentialsProvider> providers = getValidCredentialsProviders(providerNames); AWSCredentialsProvider[] ps = new AWSCredentialsProvider[providers.size()]; providers.toArray(ps); return new AWSCredentialsProviderChain(providers); } else { throw new IllegalArgumentException("Property AWSCredentialsProvider is missing."); } } AWSCredentialsProviderPropertyValueDecoder(); @Override AWSCredentialsProvider decodeValue(String value); @Override List<Class<AWSCredentialsProvider>> getSupportedTypes();  }