All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.vaadin.flow.component.grid.demo.data.TaskData Maven / Gradle / Ivy

There is a newer version: 23.0.16
Show newest version
package com.vaadin.flow.component.grid.demo.data;

import com.vaadin.flow.component.grid.demo.entity.Task;

import java.time.LocalDate;
import java.time.format.DateTimeFormatter;
import java.util.ArrayList;
import java.util.List;

public class TaskData {
    private List TASK_LIST = createTaskList();

    private List createTaskList() {
        List taskList = new ArrayList<>();

        DateTimeFormatter formatter = DateTimeFormatter.ofPattern("MM/dd/yyyy");
        taskList.add(new Task(1, "Grid demos",
                LocalDate.parse("01/01/2019", formatter)));
        taskList.add(new Task(1, "Checkbox demos",
                LocalDate.parse("02/01/2019", formatter)));
        taskList.add(new Task(1, "Date Picker demos",
                LocalDate.parse("03/01/2019", formatter)));
        taskList.add(new Task(1, "Radio Button demos",
                LocalDate.parse("04/01/2019", formatter)));
        taskList.add(new Task(1, "Text Field demos",
                LocalDate.parse("05/01/2019", formatter)));
        taskList.add(new Task(1, "Time Picker demos",
                LocalDate.parse("06/01/2019", formatter)));
        taskList.add(new Task(1, "Dialog demos ",
                LocalDate.parse("07/01/2019", formatter)));

        return taskList;
    }

    public List getTasks() {
        return TASK_LIST;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy