com.tegonal.scala.commons
Members list
Value members
Concrete methods
Intended to be used to explicitly state that we want to discard a return value.
Intended to be used to explicitly state that we want to discard a return value.
Attributes
- Since
-
0.1.0
Extensions
Extensions
Negates the receiver object, turning a true
into a false
and a false
into a true
.
Negates the receiver object, turning a true
into a false
and a false
into a true
.
Attributes
- Returns
-
the negation of the receiver object
- Since
-
0.1.0
Returns true
if the receiver object CharSequence.isEmpty as well as all chars are either Character.isWhitespace or Character.isSpaceChar, false
otherwise.
Returns true
if the receiver object CharSequence.isEmpty as well as all chars are either Character.isWhitespace or Character.isSpaceChar, false
otherwise.
Attributes
- Returns
-
true
if empty or blank,false
otherwise. - Since
-
0.1.0
Returns true
if the receiver object consists of no char, false
otherwise.
Returns true
if the receiver object consists of no char, false
otherwise.
Attributes
- Returns
-
true
if non empty,false
otherwise. - Since
-
0.1.0
Returns true if the receiver object consists of at least 1 char, false otherwise.
Returns true if the receiver object consists of at least 1 char, false otherwise.
Attributes
- Returns
-
true
if non empty,false
otherwise. - Since
-
0.1.0
Turns this Option into None if the contained String is blank.
Turns this Option into None if the contained String is blank.
Attributes
- Returns
-
None if the String is blank otherwise the String as Some.
- Since
-
0.1.0
Casts the receiver object to type T, inserting runtime checks where possible emitting a warning otherwise.
Casts the receiver object to type T, inserting runtime checks where possible emitting a warning otherwise.
Type parameters
- TSub
-
the subtype to which we want to cast
Attributes
- Returns
-
The receiver object cast to T
- Since
-
0.1.0
Applies the given function f to the receiver object.
Applies the given function f to the receiver object.
Basically the same as the scala.util.chaining.scalaUtilChainingOps, but for sure inlines and since we use it often at Tegonal and we add this library to -Yimports
we automatically have it in scope.
Type parameters
- R
-
the resulting type of the function application
Value parameters
- f
-
the function to apply to the receiver object.
Attributes
- Returns
-
the result of the function application
- Since
-
0.1.0
Perform some side effect defined in the given function f based on this receiver object.
Perform some side effect defined in the given function f based on this receiver object.
Basically the same as the scala.util.chaining.scalaUtilChainingOps, but for sure inlines and since we use it often at Tegonal and we add this library to -Yimports
we automatically have it in scope.
Value parameters
- f
-
the function which is executed, passing the receiver object as input.
Attributes
- Since
-
0.1.0
Turns this String into an Option where None is used in case this String is null or blank and Some otherwise.
Turns this String into an Option where None is used in case this String is null or blank and Some otherwise.
Attributes
- Returns
-
None if the String is blank otherwise the String as Some.
- Since
-
0.1.0
Turns this Option into None if the contained String is blank.
Turns this Option into None if the contained String is blank.
Attributes
- Returns
-
None if the String is blank otherwise the String as Some.
- Since
-
0.1.0
Turns this String into an Option where None is used in case this String is null or blank and Some otherwise.
Turns this String into an Option where None is used in case this String is null or blank and Some otherwise.
Attributes
- Returns
-
None if the String is blank otherwise the String as Some.
- Since
-
0.1.0
Turns this String into an Option where None is used in case this String is null or blank and Some otherwise.
Turns this String into an Option where None is used in case this String is null or blank and Some otherwise.
Attributes
- Returns
-
None if the String is blank otherwise the String as Some.
- Since
-
0.1.0
Turns this String into an Option where None is used in case this String is null or blank and Some otherwise.
Turns this String into an Option where None is used in case this String is null or blank and Some otherwise.
Attributes
- Returns
-
None if the String is blank otherwise the String as Some.
- Since
-
0.1.0
Map over the Failure of this Try.
Map over the Failure of this Try.
Value parameters
- f
-
the function which maps the Throwable of the current Failure to a new Throwable.
Attributes
- Returns
-
The resulting Try.
- Since
-
0.1.0