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

jdplus.toolkit.desktop.plugin.ui.processing.IProcDocumentItemFactory Maven / Gradle / Ivy

/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package jdplus.toolkit.desktop.plugin.ui.processing;

import jdplus.toolkit.desktop.plugin.util.NetBeansServiceBackend;
import jdplus.toolkit.base.api.processing.ProcDocument;
import jdplus.toolkit.base.api.util.Id;
import org.checkerframework.checker.nullness.qual.NonNull;
import org.checkerframework.checker.nullness.qual.Nullable;
import javax.swing.Action;
import javax.swing.Icon;
import javax.swing.JComponent;
import nbbrd.service.Quantifier;
import nbbrd.service.ServiceDefinition;
import nbbrd.service.ServiceSorter;

/**
 *
 * @author Philippe Charles
 */
@ServiceDefinition(
        quantifier = Quantifier.MULTIPLE,
        backend = NetBeansServiceBackend.class,
        singleton = true
)
public interface IProcDocumentItemFactory {

    @ServiceSorter
    int getPosition();

    @NonNull
    Class getDocumentType();

    @NonNull
    Id getItemId();

    @NonNull
    JComponent getView(@NonNull ProcDocument doc) throws IllegalArgumentException;

    @Nullable
    default Icon getIcon() {
        return null;
    }

    @Nullable
    default Action[] getActions() {
        return null;
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy