Alex Tkachman
|
f64c02c80a
|
test dsl example
|
2011-12-22 17:24:50 +02:00 |
|
Alex Tkachman
|
cf17beab8b
|
test dsl
|
2011-12-22 14:58:25 +02:00 |
|
James Strachan
|
2274ab48ab
|
added a useLines() methods on Reader to be able to use a line iterator (Iterator<String>) to process the file on a per line bases with the block in full control over how much of the file to process; though hit a couple of type inference issues
|
2011-12-22 09:36:18 +00:00 |
|
James Strachan
|
a7810c4396
|
another attempt at getting a flatMap test working, not quite figured out the generics yet :)
|
2011-12-22 09:09:14 +00:00 |
|
James Strachan
|
71b1aee908
|
added a little test case showing how we can iterate through lines in a file; also started adding helper methods to the standard kotlin Iterator; though probably need to rename the to* methods iterators, maybe to collect* as Stepan suggested. Could maybe use some extension function syntax making it easy to add helper methods consistently to Array, Iterator, Iterable, java.util.Iterator, java.util.Iterable at the same time, we're very inconsistent currently :)
|
2011-12-22 08:59:43 +00:00 |
|
James Strachan
|
060719e71b
|
added a test suite to run all the test cases (cheating, using java :)
|
2011-12-22 08:37:37 +00:00 |
|
James Strachan
|
894c84190a
|
migrated most of the test cases over to the new -> syntax for functions; still can't compile or run the tests yet though :(, needs more work...
|
2011-12-21 16:26:37 +00:00 |
|
James Strachan
|
232d161e99
|
added a little helper method for processing a closeable object which then makes sure the resource is closed (like the try-with-resource extension in Java 7)
|
2011-12-21 10:09:55 +00:00 |
|
James Strachan
|
c9959a10f9
|
added a couple of helper methods to Map to be able look up in a Map with function to provide a default value
|
2011-12-20 18:06:58 +00:00 |
|
James Strachan
|
c3b41a5931
|
removed a TOD section
|
2011-12-20 17:56:31 +00:00 |
|
James Strachan
|
68d527c839
|
removed some warnings and reduntant code
|
2011-12-20 17:02:30 +00:00 |
|
James Strachan
|
fee6bed2d4
|
removed the create() methods; added linkedList<T>(varargs) helper method and made filter/flatMap/map all allow an optional argument for the kind of collection to filter/flatMap/map into. I've temporarily commented out Alex's implementation of Iterable.filter in Filters.kt as I was getting all kinds of compile error messages. Will discuss this on the list & how better to organise the functions into files
|
2011-12-20 16:28:18 +00:00 |
|
James Strachan
|
7e93494e2f
|
renamed the sort() methods on Iterable which create a new List and sort that as "toSortedList()" instead which is more accurate.
|
2011-12-18 08:15:39 +00:00 |
|
James Strachan
|
d122929b4b
|
first cut of the collection methods in the standard library in http://confluence.jetbrains.net/display/JET/Standard+Library along with a little testlib to test them. Still a few TODO things and tidy up (and am sure a few more methods could be very handy too) but its getting Kool :)
|
2011-12-18 07:17:38 +00:00 |
|