Class ConfigData$

java.lang.Object
csw.config.api.ConfigData$

public class ConfigData$ extends Object
Provides various alternatives for constructing the data to be stored in the config service.
  • Field Details

    • MODULE$

      public static final ConfigData$ MODULE$
      Static reference to the singleton instance of this Scala object.
  • Constructor Details

    • ConfigData$

      public ConfigData$()
  • Method Details

    • fromString

      public ConfigData fromString(String str)
      Create ConfigData from string

      Parameters:
      str - the string which needs to be converted to ConfigData
      Returns:
      the ConfigData created from the given string
    • fromPath

      public ConfigData fromPath(Path path)
      Create ConfigData from file path

      Parameters:
      path - the path which needs to be converted to ConfigData
      Returns:
      the ConfigData created from the given path
    • fromBytes

      public ConfigData fromBytes(byte[] bytes)
      Create ConfigData from byte array

      Parameters:
      bytes - an array of bytes that is converted to ConfigData
      Returns:
      the ConfigData created from the given array of bytes
    • from

      public ConfigData from(akka.stream.scaladsl.Source<akka.util.ByteString,Object> dataBytes, long length)
      An internally used method to create that take an akka source and length of data and creates a ConfigData instance out of it

      Parameters:
      dataBytes - an akka source that materializes to stream of bytes
      length - the length representing number of bytes
      Returns:
      the ConfigData instance created out of provided dataBytes and length