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

io.mateu.mdd.vaadin.controllers.secondLevel.CustomComponentController Maven / Gradle / Ivy

There is a newer version: 1.1.60
Show newest version
package io.mateu.mdd.vaadin.controllers.secondLevel;

import io.mateu.mdd.core.app.MDDOpenCustomComponentAction;
import io.mateu.mdd.vaadin.components.ComponentWrapper;
import io.mateu.mdd.vaadin.controllers.Controller;
import io.mateu.mdd.vaadin.navigation.ViewStack;

public class CustomComponentController extends Controller {
    private final MDDOpenCustomComponentAction action;

    public CustomComponentController(MDDOpenCustomComponentAction action) {
        this.action = action;
    }

    @Override
    public Object apply(ViewStack stack, String path, String step, String cleanStep, String remaining) throws Throwable {
        return new ComponentWrapper(action.getIcon(), action.getCaption(), action.getComponent(), false);
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy