Blog: Software Craftsman's Blog

Functional approach to Exception handling in Scala

Did you know that in functional programming world there is a criticizm of throwing excepions? It seems that it would break a functional programming principle that a function have to always return a va...

Wyświetlenia 842

OK 0

NOK 0

Writing a simplified JSON parser in Clojure

Today I want to write a step by step example of creating a parser for JSON. What is extraordinary, I'll use a Clojure to do that. This is because I have to learn Clojure for my current job and I ...

Wyświetlenia 528

OK 0

NOK 0

Scalatra - How to setup with Maven and Jetty

Recently I was inspired by a colleague to dig into AngularJS and Scalatra web application stack, so today I'll continue with first steps in digging into Scalatra.Description from www.scalatra.org:Scal...

Wyświetlenia 502

OK 0

NOK 0

AngularJS example - simple calculator

Recently my attention was focused on a very interesting JavaScript framework named AngularJS. It is a framework created by Google to augment creation of rich browser-based application. In this article...

Wyświetlenia 635

OK 0

NOK 0

Faking System Clock with metaprogramming pattern in Scala

Tomasz Nurkiewicz has written an article Fake system clock pattern in Scala with implicit parameters on his blog. The problem he addresses is that sometimes you require to test your business code agai...

Wyświetlenia 563

OK 0

NOK 0

Metaprogramming in Scala with higher order functions

Scala is very flexible programming language. In this article I would like to propose some usage pattern for higher order functions. This pattern could help us to create a convenient way to handle mult...

Wyświetlenia 772

OK 0

NOK 0

Neat and simple way to measure code performance in Scala

When we write a source code we often have to be aware of the performace of our solution. The easiest way to achieve this is by measuring duration of the execution by taking the system time before and ...

Wyświetlenia 555

OK 0

NOK 0

Scala - Parentheses and Curly Brackets in Anonymous Functions

Scala gives a lot of flexibility in defining anonymous functions, and that might lead to a confussion. Jacek Laskowski asked an interesting question on stackoverflow.com regarding of calling a map met...

Wyświetlenia 489

OK 0

NOK 0

Named and Default parameters inconsistency in Scala

While I was reading Scala in Depth I've run into an interesting problem related to named method parameters and class inheritance. What will happen, when in child class we'll override method ...

Wyświetlenia 799

OK 0

NOK 0

List sorting in Scala

While I was watching Jacek Laskowski (polish blog) working on taskassin (also in polish) and Scala programming I decided to summarize different approches to List sorting in Scala.In Jacek's problem we...

Wyświetlenia 308

OK 0

NOK 0

Scalatron Bot Mars imporved to reach 7.5 million energy points in benchmark!

Hi, after playing a little more with Scalatron I've improved my bot in few areas:Minibots count - now my bot can spawn more mini bots and also my mini bots can spawn other mini bots so they have much ...

Wyświetlenia 336

OK 0

NOK 0

Bot for Scalatron – great way to practice Scala

Recently I was pointed to project Scalatron which is a programming game, where bots are fighting in simple arena. The main goal is to capture as many energy points as possible, or at least more than y...

Wyświetlenia 336

OK 0

NOK 0

Spock testing framework introduction

During 33rd Degree conference that took place in Warsaw in the middle on March 2013 I was listening to Ken Sipe’s speech entitled Mocking, Stubbing and Spying with Spock. This has been very interestin...

Wyświetlenia 342

OK 0

NOK 0

Maven configuration example for Scala

When you start to learn Scala, you might like to use tools that you are familiar to. I.e. you would like to use well known Maven to build your project and manage dependencies. In this post I’ll show y...

Wyświetlenia 326

OK 0

NOK 0

Testing yourself in Codility

Today I've checked how Codility tests programmers. And it looks like a fun. After you access a test (possibly to get certificate) you will have access to some simple web IDE where you will write your ...

Wyświetlenia 426

OK 0

NOK 0

Scala, gson and Option

During development of my pet project written in Scala I've run into a problem when trying to serialize Option object into Json using gson library. This is problem, because Gson have implemented serial...

Wyświetlenia 345

OK 0

NOK 0

Polskie blogi o JAVIE

                                                                                                                                       

dailylog

Wpisów: 34

Ostatni (2014-10-06):
PageLogic

    

jdn.pl

Wpisów: 163

Ostatni (2015-01-09):
Chamberconf