SimpleConfigOrigin

org.ekrich.config.impl.SimpleConfigOrigin
See theSimpleConfigOrigin companion object
final class SimpleConfigOrigin extends ConfigOrigin

Attributes

Companion
object
Graph
Supertypes
trait ConfigOrigin
class Object
trait Matchable
class Any

Members list

Value members

Concrete methods

override def comments: List[String]

Returns any comments that appeared to "go with" this place in the file. Often an empty list, but never null. The details of this are subject to change, but at the moment comments that are immediately before an array element or object field, with no blank line after the comment, "go with" that element or field.

Returns any comments that appeared to "go with" this place in the file. Often an empty list, but never null. The details of this are subject to change, but at the moment comments that are immediately before an array element or object field, with no blank line after the comment, "go with" that element or field.

Attributes

Returns

any comments that seemed to "go with" this origin, empty list if none

Definition Classes
override def description: String

Returns a string describing the origin of a value or exception. This will never return null.

Returns a string describing the origin of a value or exception. This will never return null.

Attributes

Returns

string describing the origin

Definition Classes
override def equals(other: Any): Boolean

Compares the receiver object (this) with the argument object (that) for equivalence.

Compares the receiver object (this) with the argument object (that) for equivalence.

Any implementation of this method should be an equivalence relation:

  • It is reflexive: for any instance x of type Any, x.equals(x) should return true.
  • It is symmetric: for any instances x and y of type Any, x.equals(y) should return true if and only if y.equals(x) returns true.
  • It is transitive: for any instances x, y, and z of type Any if x.equals(y) returns true and y.equals(z) returns true, then x.equals(z) should return true.

If you override this method, you should verify that your implementation remains an equivalence relation. Additionally, when overriding this method it is usually necessary to override hashCode to ensure that objects which are "equal" (o1.equals(o2) returns true) hash to the same scala.Int. (o1.hashCode.equals(o2.hashCode)).

Value parameters

that

the object to compare against this object for equality.

Attributes

Returns

true if the receiver object is equivalent to the argument; false otherwise.

Definition Classes
Any
override def filename: String

Returns a filename describing the origin. This will return null if the origin was not a file.

Returns a filename describing the origin. This will return null if the origin was not a file.

Attributes

Returns

filename of the origin or null

Definition Classes
override def hashCode: Int

Calculate a hash code value for the object.

Calculate a hash code value for the object.

The default hashing algorithm is platform dependent.

Note that it is allowed for two objects to have identical hash codes (o1.hashCode.equals(o2.hashCode)) yet not be equal (o1.equals(o2) returns false). A degenerate implementation could always return 0. However, it is required that if two objects are equal (o1.equals(o2) returns true) that they have identical hash codes (o1.hashCode.equals(o2.hashCode)). Therefore, when overriding this method, be sure to verify that the behavior is consistent with the equals method.

Attributes

Returns

the hash code value for this object.

Definition Classes
Any
override def lineNumber: Int

Returns a line number where the value or exception originated. This will return -1 if there's no meaningful line number.

Returns a line number where the value or exception originated. This will return -1 if there's no meaningful line number.

Attributes

Returns

line number or -1 if none is available

Definition Classes
override def resource: String

Returns a classpath resource name describing the origin. This will return null if the origin was not a classpath resource.

Returns a classpath resource name describing the origin. This will return null if the origin was not a classpath resource.

Attributes

Returns

resource name of the origin or null

Definition Classes
override def toString: String

Returns a string representation of the object.

Returns a string representation of the object.

The default representation is platform dependent.

Attributes

Returns

a string representation of the object.

Definition Classes
Any
override def url: URL

Returns a URL describing the origin. This will return null if the origin has no meaningful URL.

Returns a URL describing the origin. This will return null if the origin has no meaningful URL.

Attributes

Returns

url of the origin or null

Definition Classes
override def withComments(comments: List[String]): SimpleConfigOrigin

Returns a ConfigOrigin based on this one, but with the given comments. Does not modify this instance or any ConfigValues with this origin (since they are immutable). To set the returned origin to a ConfigValue, use ConfigValue#withOrigin.

Returns a ConfigOrigin based on this one, but with the given comments. Does not modify this instance or any ConfigValues with this origin (since they are immutable). To set the returned origin to a ConfigValue, use ConfigValue#withOrigin.

Note that when the given comments are equal to the comments on this object, a new instance may not be created and this is returned directly.

Value parameters

comments

the comments used on the returned origin

Attributes

Returns

the ConfigOrigin with the given comments

Since

1.3.0

Definition Classes
override def withLineNumber(lineNumber: Int): SimpleConfigOrigin

Returns a ConfigOrigin based on this one, but with the given line number. This origin must be a FILE, URL or RESOURCE. Does not modify this instance or any ConfigValues with this origin (since they are immutable). To set the returned origin to a ConfigValue, use ConfigValue#withOrigin.

Returns a ConfigOrigin based on this one, but with the given line number. This origin must be a FILE, URL or RESOURCE. Does not modify this instance or any ConfigValues with this origin (since they are immutable). To set the returned origin to a ConfigValue, use ConfigValue#withOrigin.

Note that when the given lineNumber are equal to the lineNumber on this object, a new instance may not be created and this is returned directly.

Value parameters

lineNumber

the new line number

Attributes

Returns

the created ConfigOrigin

Since

1.3.0

Definition Classes

Concrete fields

val _description: String
val _lineNumber: Int
val commentsOrNull: List[String]
val endLineNumber: Int
val resourceOrNull: String
val urlOrNull: String