Questions tagged [lambdaj]

LambdaJ is a library to manipulate a collections without any iterations.

LambdaJ is a library to manipulate a collections without any iterations. It allows to manipulate collections in a pseudo-functional and statically typed way.

The purpose of this library is to alleviate these problems employing some functional programming techniques but without losing the static typing of java. LambdaJ team imposes this last constraint to make refactoring easier and safer and allow the compiler to do its job.

For more information refer this : http://code.google.com/p/lambdaj/

84 questions
2
votes
0 answers

Extract object from list java with lambdaj

I have a list of with some fields, one of these is "number plate". From the HTML arrives the number plate and I want extract the object car with number plate equal to that which arrives. I want use lambdaj but I have a some problem. Car…
Marco_dev
  • 53
  • 6
2
votes
1 answer

Android LambdaJ - unable to use, exception on every call

I'm using lambdaj 2.4 with dependencies. My code (very simple): List persons = Arrays.asList( new Person(13,"Steve",22,"London, UK"), new Person(25,"Greg",28,"New York, USA"), new…
user1209216
  • 5,410
  • 7
  • 45
  • 95
2
votes
2 answers

lambdaj installation

we have downloaded jar files for lambdaj and its dependencies which are again jar files. we do not know how to go about it. we have copied these files in the C:\Program Files\Java\jre6\lib\ext have set the class path in environment variales…
intern
  • 141
  • 1
  • 5
2
votes
1 answer

Hamcrest - any item in arrayOne matches any item in arrayTwo

I am using LambdaJ and hamcrest in Java. I am wondering if there is a way to check if any item in one array is equal to any item of another array? I have tried some configurations but I can not seem to get it right. like this one: arrayOne,…
Jonas.z
  • 366
  • 2
  • 15
2
votes
1 answer

lambdaj fails java.lang.ExceptionInInitializerError with any call on Android

I'm trying to use lambdaj on Android but with every simple call I make I get an exception (java.lang.ExceptionInInitializerError). The class that fills the collection is: @DatabaseTable(tableName = "sections") public class Section { …
Gonan
  • 440
  • 6
  • 17
2
votes
2 answers

How can I use lambdaj in my application

This may sound like a stupid question, but how can I start to use lambdaj library? I downloaded the lambdaj.jar and put it in the lib directory in my webapp together with other jar files. But I can't import any of the classes. Do I need to build the…
David Zhao
  • 3,726
  • 11
  • 42
  • 58
2
votes
1 answer

Comparing objects using hamcrest and lambdaj based on multiple inputs

I am trying to filter an array list to remove objects that do not match a set of criteria input by a user. The object has 3 lists. See below for example. public class A { public String [] a={"a", "b", "c"}; public String [] c={"a", "b",…
Xander
  • 121
  • 3
2
votes
1 answer

how to use lambdaj with hamcrest matcher (hasItemsInArray) for filtering a list

I'm trying to filter a list of caroffers Objects which are found in vendor array through lambdaj. But the below code doesn't work. I'm getting empty list. String[] vendor = {"FORD","TOYOTA"}; List…
Kumar
  • 43
  • 1
  • 8
2
votes
1 answer

Employing Two Separate Filtering Criteria, using Lambdaj

Using Lambdaj, I am trying to isolate, from a list, an object that satisfies 2 separate criteria. Both of the following will achieve my goal. A) List someObjectsWithMatchingSomeObjectIds =…
HellishHeat
  • 1,920
  • 4
  • 23
  • 35
2
votes
1 answer

Simple select method (lambdaj) gets Exception

I'm newbie to lambdaj. It seems that a great feature for Java programming. So I created a very simple program for evaluating. But I got a Exception for codes below. Could you help me what is wrong? --EDITED added no argument constructor and public…
user1209133
  • 167
  • 1
  • 2
  • 7
1
vote
1 answer

LambdaJ Experts... how to randomize output

I have been trying to teach myself Lambdaj and it doesn't seem to want to randomize my string array. Should I add the strings to a List to be able to work with the collection with Lambdaj. All I want to do is take a collection of strings and print…
Dave_P
  • 164
  • 1
  • 15
1
vote
1 answer

how to filter a table use lambdaj or other tools

How can I filter a table using lambdaj? Given the following table: id name age male salary 1 tom 22 y 3k 2 nancy 24 n 3.5k 3 jack 22 y 2k 4 jmme 29 y 4k If I applied the filter: age >= 22 &&…
Jackie
  • 21
  • 4
1
vote
1 answer

Lambdaj or apache predicate for filtering and modifying list item

I am working on a data loader, implemented using Spring Batch i.e. reading multiple flat files, processing and writing the list of pojo at commit interval of 1000 to database. Each line read from file is converted to a pojo object containing…
Dead Programmer
  • 11,879
  • 20
  • 75
  • 110
1
vote
4 answers

LINQ's Single in java?

Is there an equivalent to LINQ's Single in java? Perhaps in lambdaj?
ripper234
  • 202,011
  • 255
  • 600
  • 878
1
vote
1 answer

Map two ArrayList with lambdaj?

I have two classes public class User { private int _Id; private String _FirstName; private String _LastName;} and public class Card { private int _Id; private int _UserId; private String _Serial;} I have Array of User[]…
Pavol
  • 422
  • 5
  • 17