// SPDX-FileCopyrightText: 2020 Roberto Posenato // // SPDX-License-Identifier: LGPL-3.0-or-later package it.univr.di.cstnu.graph; import edu.umd.cs.findbugs.annotations.SuppressFBWarnings; import it.unimi.dsi.fastutil.objects.Object2IntArrayMap; import it.unimi.dsi.fastutil.objects.Object2IntMap; import it.unimi.dsi.fastutil.objects.Object2IntMap.Entry; import it.unimi.dsi.fastutil.objects.ObjectSet; import it.univr.di.Debug; import it.univr.di.labeledvalue.*; import javax.annotation.Nonnull; import java.io.Serial; import java.util.logging.Level; import java.util.logging.Logger; /** * An implementation of CSTNEdge where the kind of labeled value map can be configured at initialization (new) time. * * @author posenato * @version $Rev$ */ public class CSTNEdgePluggable extends AbstractEdge implements CSTNEdge { /** * Default class for representing labeled values. It should minimize the set of represented labeled values as much as possible. */ static final Class DEFAULT_LABELED_INT_MAP_CLASS = LabeledIntTreeMap.class; /** * */ @Serial private static final long serialVersionUID = 6L; /** * logger */ @SuppressWarnings("NonConstantLogger")//because subclasses can re-assign with a proper argument static Logger LOG = Logger.getLogger(CSTNEdgePluggable.class.getName()); /** * Labeled value class used in the class. */ final Class labeledValueMapImpl; /** * Maintains log of labeled values that have been already inserted and, therefore, cannot be reinserted. This is used for speed-up the label management. */ Object2IntMap