fix constructor to 1 argument, add parse method