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

com.ibm.wala.fixpoint.IFixedPointStatement Maven / Gradle / Ivy

The newest version!
/*
 * Copyright (c) 2002 - 2006 IBM Corporation.
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 *
 * Contributors:
 *     IBM Corporation - initial API and implementation
 */
package com.ibm.wala.fixpoint;

import com.ibm.wala.util.graph.INodeWithNumber;
import org.jspecify.annotations.Nullable;

/**
 * The general form of a statement definition in an iterative solver is: x >= term, where term
 * can be any complex expression whose free variables are among the IVariables of the constraint
 * system this {@link IFixedPointStatement}is part of (x represents the left-hand side of the
 * constraint). The interpretation of term (the right-hand side of the constraint) must be monotone.
 *
 * 

The list of free variables in term is obtained by invoking {@link #getRHS()}, and the left * hand side variable is obtained by calling {@link #getLHS()}. Intuitively, a statement definition * corresponds to an "equation" in dataflow parlance, or a "constraint" in constraint solvers. */ public interface IFixedPointStatement> extends INodeWithNumber { /** * @return the left-hand side of this statement. */ @Nullable T getLHS(); /** returns the list of free variables appearing in the right-hand side of the statement */ T[] getRHS(); /** * Evaluate this statement, setting a new value for the left-hand side. The return value is one of * the following: * *

    *
  • {@link FixedPointConstants#CHANGED}, *
  • {@link FixedPointConstants#CHANGED_AND_FIXED}, *
  • {@link FixedPointConstants#NOT_CHANGED}, or *
  • {@link FixedPointConstants#NOT_CHANGED_AND_FIXED}. *
*/ byte evaluate(); /** * Does this statement definition contain an appearance of a given variable? * * @param v the variable in question */ boolean hasVariable(T v); }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy