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

cdc.mf.checks.nodes.interfaces.DefaultInterfacesChecker Maven / Gradle / Ivy

The newest version!
package cdc.mf.checks.nodes.interfaces;

import java.util.List;

import cdc.issues.checks.AbstractPartsChecker;
import cdc.issues.checks.SnapshotManager;
import cdc.issues.locations.LocatedObject;
import cdc.mf.model.MfInterface;
import cdc.mf.model.MfQNameItem;
import cdc.mf.model.MfTypeOwner;

public class DefaultInterfacesChecker extends AbstractPartsChecker {
    public static final String KEY = "DefaultInterfacesChecker";

    public DefaultInterfacesChecker(SnapshotManager manager) {
        super(manager,
              MfTypeOwner.class,
              MfInterface.class,
              new DefaultInterfaceChecker(manager));
        manager.register(KEY, this);
    }

    @Override
    protected List> getParts(MfTypeOwner object) {
        final List delegates = object.getInterfaces()
                                                  .stream()
                                                  .sorted(MfQNameItem.QNAME_COMPARATOR)
                                                  .toList();
        return LocatedObject.locate(delegates);
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy