public @ResponseBody List<SerializableTask> getAllTasksOfUserstory(@PathVariable Integer userstoryid) {
Set<Task> tasks = this.taskService.getAllTasksByUserstoryId(userstoryid);
List<SerializableTask> serializedTasks = new ArrayList<SerializableTask>();
for (Iterator<Task> iterator = tasks.iterator(); iterator.hasNext();) {
Task t = iterator.next();
SerializableTask st = new SerializableTask(t.getId(), t.getDescription(), t.getxCoord(),
t.getyCoord(), t.getStatus(), t.getDuration(), t.getCreationDate());
serializedTasks.add(st);
}
return serializedTasks;
}