![JAR search and dependency download from the Maven repository](/logo.png)
org.ggp.base.util.gdl.model.assignments.FunctionInfo Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of alloy-ggp-base Show documentation
Show all versions of alloy-ggp-base Show documentation
A modified version of the GGP-Base library for Alloy.
The newest version!
package org.ggp.base.util.gdl.model.assignments;
import java.util.List;
import java.util.Map;
import java.util.Set;
import org.ggp.base.util.gdl.grammar.GdlConstant;
import org.ggp.base.util.gdl.grammar.GdlSentence;
import org.ggp.base.util.gdl.grammar.GdlVariable;
import org.ggp.base.util.gdl.model.SentenceForm;
import com.google.common.collect.ImmutableList;
public interface FunctionInfo {
/**
* Returns the SentenceForm that this functionality information
* is defined for.
*/
SentenceForm getSentenceForm();
/**
* Returns a list of boolean values indicating which slots in
* the given sentence form can be determined from the remaining
* slots. (For example, in a successor function, either slot's
* value would be uniquely determined by the other slot's, so
* this would return [true, true].)
*/
List getDependentSlots();
/**
* Given a sentence of the constant form's sentence form, finds all
* the variables in the sentence that can be produced functionally.
* That is, the value of any one variable in this set can be determined
* given that every other variable in the sentence is already defined.
*
* Note the corner case: If a variable appears twice in a sentence,
* it CANNOT be produced in this way.
*/
//TODO: Replace with utility function in FunctionInfos
Set getProducibleVars(GdlSentence sentence);
/**
* Returns a map from input tuples to results for the given slot of
* the sentence form. The format for input tuples is a list of
* GdlConstants of size (n-1), where n is the tuple size of the
* sentence form. The input tuple contains every constant in the
* sentence, in order, except for the slot of interest, which is
* omitted from that list.
*/
Map, GdlConstant> getValueMap(int varIndex);
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy