major update with changed / added functionality and some junit tests