final class ConfigObjectSource extends ConfigSource
A ConfigSource which is guaranteed to generate config objects (maps) as root values.
- Alphabetic
- By Inheritance
- ConfigObjectSource
- ConfigSource
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
at(namespace: String): ConfigSource
Navigates through the config to focus on a namespace.
Navigates through the config to focus on a namespace.
- namespace
the namespace to focus on
- returns
a new
ConfigSourcefocused on the given namespace.
- Definition Classes
- ConfigSource
-
def
clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
-
def
config(): Result[Config]
Reads a
Configfrom this config source.Reads a
Configfrom this config source. The returned config is usually unresolved, unless the source forces it otherwise.- returns
a
Configprovided by this source.
-
def
cursor(): Result[ConfigCursor]
Returns a cursor for a
ConfigValueretrieved from this source.Returns a cursor for a
ConfigValueretrieved from this source.- returns
a cursor for a
ConfigValueretrieved from this source.
- Definition Classes
- ConfigObjectSource → ConfigSource
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
def
fluentCursor(): FluentConfigCursor
Returns a fluent cursor for a
ConfigValueretrieved from this source.Returns a fluent cursor for a
ConfigValueretrieved from this source.- returns
a fluent cursor for a
ConfigValueretrieved from this source.
- Definition Classes
- ConfigSource
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
final
def
load[A](implicit reader: Derivation[ConfigReader[A]]): Result[A]
Loads a configuration of type
Afrom this source.Loads a configuration of type
Afrom this source.- A
the type of the config to be loaded
- returns
A
Rightwith the configuration if it is possible to create an instance of typeAfrom this source, aFailurewith details on why it isn't possible otherwise
- Definition Classes
- ConfigSource
-
final
def
loadOrThrow[A](implicit arg0: ClassTag[A], reader: Derivation[ConfigReader[A]]): A
Loads a configuration of type
Afrom this source.Loads a configuration of type
Afrom this source. If it is not possible to create an instance ofA, this method throws aConfigReaderException.- A
the type of the config to be loaded
- returns
The configuration of type
Aloaded from this source.
- Definition Classes
- ConfigSource
- Annotations
- @throws( ... )
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
def
optional: ConfigObjectSource
Returns a
ConfigObjectSourcethat provides the same config as this one, but falls back to providing an empty config when the source cannot be read.Returns a
ConfigObjectSourcethat provides the same config as this one, but falls back to providing an empty config when the source cannot be read. It can be used together with.withFallbackto specify optional config files to be merged (likereference.conf).- returns
a new
ConfigObjectSourcethat provides the same config as this one, but falls back to an empty config if it cannot be read.
-
def
recoverWith(f: PartialFunction[ConfigReaderFailures, ConfigObjectSource]): ConfigObjectSource
Applies a function
fif this source returns a failure, returning an alternative config source in those cases.Applies a function
fif this source returns a failure, returning an alternative config source in those cases.- f
the function to apply if this source returns a failure
- returns
a new
ConfigObjectSourcethat provides an alternative config in case this source fails
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
toString(): String
- Definition Classes
- AnyRef → Any
-
def
value(): Result[ConfigObject]
Retrieves a
ConfigValuefrom this source.Retrieves a
ConfigValuefrom this source. This forces the config to be resolved, if needed.- returns
a
ConfigValueretrieved from this source.
- Definition Classes
- ConfigObjectSource → ConfigSource
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
-
def
withFallback(cs: ConfigObjectSource): ConfigObjectSource
Merges this source with another one, with the latter being used as a fallback (e.g.
Merges this source with another one, with the latter being used as a fallback (e.g. the source on which this method is called takes priority). Both sources are required to produce a config object successfully.
- cs
the config source to use as fallback
- returns
a new
ConfigObjectSourcethat loads configs from both sources and usescsas a fallback for this source