com.hazelcast.client.config

## Class ClientClasspathYamlConfig

- java.lang.Object
- - com.hazelcast.client.config.ClientConfig
  - - com.hazelcast.client.config.ClientClasspathYamlConfig

-     public class ClientClasspathYamlConfig
      extends ClientConfig

  A `ClientConfig` which is initialized by loading an YAML configuration file from the classpath.

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `ClientClasspathYamlConfig(ClassLoader classLoader, String resource, Properties properties)` Creates a config which is loaded from a classpath resource.
    `ClientClasspathYamlConfig(String resource)` Creates a config which is loaded from a classpath resource using the `Thread.currentThread()` contextClassLoader.
    `ClientClasspathYamlConfig(String resource, Properties properties)` Creates a config which is loaded from a classpath resource using the `Thread.currentThread()` contextClassLoader.

  - ### Method Summary

    - ### Methods inherited from class com.hazelcast.client.config.ClientConfig

      `addAddress, addFlakeIdGeneratorConfig, addLabel, addListenerConfig, addNearCacheConfig, addNearCacheConfig, addProxyFactoryConfig, addQueryCacheConfig, addReliableTopicConfig, equals, findFlakeIdGeneratorConfig, getAddresses, getClassLoader, getConfigPatternMatcher, getConnectionAttemptLimit, getConnectionAttemptPeriod, getConnectionStrategyConfig, getConnectionTimeout, getCredentials, getExecutorPoolSize, getFlakeIdGeneratorConfig, getFlakeIdGeneratorConfigMap, getGroupConfig, getInstanceName, getLabels, getLicenseKey, getListenerConfigs, getLoadBalancer, getManagedContext, getNativeMemoryConfig, getNearCacheConfig, getNearCacheConfigMap, getNetworkConfig, getOrCreateQueryCacheConfig, getOrNullQueryCacheConfig, getProperties, getProperty, getProxyFactoryConfigs, getQueryCacheConfigs, getReliableTopicConfig, getReliableTopicConfigMap, getSecurityConfig, getSerializationConfig, getSocketInterceptorConfig, getSocketOptions, getUserCodeDeploymentConfig, getUserContext, hashCode, isRedoOperation, isSmartRouting, setAddresses, setClassLoader, setConfigPatternMatcher, setConnectionAttemptLimit, setConnectionAttemptPeriod, setConnectionStrategyConfig, setConnectionTimeout, setCredentials, setExecutorPoolSize, setFlakeIdGeneratorConfigMap, setGroupConfig, setInstanceName, setLabels, setLicenseKey, setListenerConfigs, setLoadBalancer, setManagedContext, setNativeMemoryConfig, setNearCacheConfigMap, setNetworkConfig, setProperties, setProperty, setProxyFactoryConfigs, setQueryCacheConfigs, setRedoOperation, setReliableTopicConfigMap, setSecurityConfig, setSerializationConfig, setSmartRouting, setSocketInterceptorConfig, setSocketOptions, setUserCodeDeploymentConfig, setUserContext`

    - ### Methods inherited from class java.lang.Object

      `clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### ClientClasspathYamlConfig

          public ClientClasspathYamlConfig(String resource)

      Creates a config which is loaded from a classpath resource using the `Thread.currentThread()` contextClassLoader. The System.properties are used to resolve variables in the YAML.
      Parameters:
        `resource` - the resource, a YAML configuration file from the classpath, without the "classpath:" prefix
      Throws:
        `IllegalArgumentException` - if the resource could not be found
        `InvalidConfigurationException` - if the YAML content is invalid

    - #### ClientClasspathYamlConfig

          public ClientClasspathYamlConfig(String resource,
                                           Properties properties)

      Creates a config which is loaded from a classpath resource using the `Thread.currentThread()` contextClassLoader.
      Parameters:
        `resource` - the resource, a YAML configuration file from the classpath, without the "classpath:" prefix
        `properties` - the Properties to resolve variables in the YAML
      Throws:
        `IllegalArgumentException` - if the resource could not be found or if properties is `null`
        `InvalidConfigurationException` - if the YAML content is invalid

    - #### ClientClasspathYamlConfig

          public ClientClasspathYamlConfig(ClassLoader classLoader,
                                           String resource,
                                           Properties properties)

      Creates a config which is loaded from a classpath resource.
      Parameters:
        `classLoader` - the ClassLoader used to load the resource
        `resource` - the resource, a YAML configuration file from the classpath, without the "classpath:" prefix
        `properties` - the properties used to resolve variables in the YAML
      Throws:
        `IllegalArgumentException` - if classLoader or resource is `null`, or if the resource is not found
        `InvalidConfigurationException` - if the YAML content is invalid

Copyright © 2020. All rights reserved.