Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance. Project price only 1 $
You can buy this project and download/modify it how often you want.
/*
* Copyright (C) 2010-2023, Danilo Pianini and contributors
* listed, for each module, in the respective subproject's build.gradle.kts file.
*
* This file is part of Alchemist, and is distributed under the terms of the
* GNU General Public License, with a linking exception,
* as described in the file LICENSE in the Alchemist distribution's top directory.
*/
package it.unibo.alchemist.model.sapere.conditions;
import it.unibo.alchemist.model.sapere.dsl.impl.NumTreeNode;
import it.unibo.alchemist.model.sapere.dsl.IExpression;
import it.unibo.alchemist.model.sapere.dsl.ITreeNode;
import it.unibo.alchemist.model.sapere.molecules.LsaMolecule;
import it.unibo.alchemist.model.Context;
import it.unibo.alchemist.model.Environment;
import it.unibo.alchemist.model.sapere.ILsaMolecule;
import it.unibo.alchemist.model.sapere.ILsaNode;
import it.unibo.alchemist.model.Node;
import it.unibo.alchemist.model.Reaction;
import org.danilopianini.lang.HashString;
import java.util.AbstractSet;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.LinkedHashSet;
import java.util.List;
import java.util.Map;
/**
*/
public final class LsaNeighborhoodCondition extends LsaStandardCondition {
private static final long serialVersionUID = 5472803597473997104L;
private final Environment, ?> environment;
/**
* @param node the node
* @param molecule the molecule
* @param environment the environment
*/
public LsaNeighborhoodCondition(
final ILsaNode node,
final ILsaMolecule molecule,
final Environment, ?> environment
) {
super(molecule, node);
this.environment = environment;
}
@Override
public LsaNeighborhoodCondition cloneCondition(final Node> node, final Reaction> r) {
return new LsaNeighborhoodCondition((ILsaNode) node, getMolecule(), environment);
}
@Override
public boolean filter(
final List