Package com.typesafe.config
Class ConfigOriginFactory
java.lang.Object
com.typesafe.config.ConfigOriginFactory
This class contains some static factory methods for building a
ConfigOrigin
. ConfigOrigin
s are automatically created when you
call other API methods to get a ConfigValue
or Config
.
But you can also set the origin of an existing ConfigValue
, using
ConfigValue.withOrigin(ConfigOrigin)
.- Since:
- 1.3.0
-
Method Summary
Modifier and TypeMethodDescriptionstatic ConfigOrigin
Creates a file origin with the given filename.static ConfigOrigin
Returns the default origin for values when no other information is provided.static ConfigOrigin
Returns an origin with the given description.static ConfigOrigin
Creates a url origin with the given URL object.
-
Method Details
-
newSimple
Returns the default origin for values when no other information is provided. This is the origin used in#fromAnyRef(Object)
.- Returns:
- the default origin
- Since:
- 1.3.0
-
newSimple
Returns an origin with the given description.- Parameters:
description
- brief description of what the origin is- Returns:
- a new origin
- Since:
- 1.3.0
-
newFile
Creates a file origin with the given filename.- Parameters:
filename
- the filename of this origin- Returns:
- a new origin
- Since:
- 1.3.0
-
newURL
Creates a url origin with the given URL object.- Parameters:
url
- the url of this origin- Returns:
- a new origin
- Since:
- 1.3.0
-