Questions tagged [vavr]

Questions about the Vavr functional programming library (formerly known as Javaslang).

Vavr (formerly known as Javaslang) is an open-source, functional component library for Java 8+.

Vavr provides immutable collections and the necessary functions and control structures to operate on these values. Most Vavr data structures are purely functional, i.e. they are both immutable and persistent. Operations that appear to modify a purely functional data structure do not alter the underlying data, but instead create a new version (and, in Vavr, a new Java object); references to the old version remain valid.

(For efficiency, persistent data structures are generally implemented so as to share as much state between versions as possible.)

See Also:

154 questions
-1
votes
1 answer

Creating query with Option as parameter

I'm trying to make a mongo query (using Spring Data) for searching record by the Option value from Vavr. I have value Option userId and I'm wondering if it's possible to search in database by this parameter. I have serched in MongoDB and Spring…
-1
votes
1 answer

RuntimeException treated as ServerSOAPFaultException

Why following code: /.../ .onFailure(exc -> Match(exc).of( Case($(instanceOf(ServerSOAPFaultException.class)), handleServerSOAPFaultException(exc)), …
PoorGuy
  • 29
  • 8
-1
votes
1 answer

Why isn't Vavr Either is recognizing the parameter to map() function?

I am dirtying my hands with the fantastic library of vavr (0.9.2). Here's a code snippet, that aims to collect an Either: Either,String>, List> payloadPreparationResult = new…
Nirmalya
  • 717
  • 9
  • 19
-3
votes
1 answer

Iterate over regex in vavr

What is the idiomatic way to iterate over the matches returned by a regexp in java. Usually the java way is the following (see How to iterate over regex expression) Pattern p = Pattern.compile("(\\w+)=(\\w+);"); Matcher m = p.matcher(line); while…
raisercostin
  • 8,777
  • 5
  • 67
  • 76
1 2 3
10
11