|
JML | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.jmlspecs.samples.misc.LinearSearch
A linear search component, intended to demonstrate verification in JML specifications. This class has two abstract methods that describe the search, which need to be filled in to instantiate it. The formulation of the search and the verification is based on Edward Cohen's book Programming in the 1990s (Springer-Verlag, 1990).
| Constructor Summary | |
LinearSearch()
|
|
| Method Summary | |
abstract boolean |
f(int j)
The function that describes what is being sought. |
int |
find()
Find a solution to the searching problem. |
abstract int |
limit()
The last integer in the search space, this describes the domain of f, which goes from 0 to the result. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public LinearSearch()
| Method Detail |
public abstract boolean f(int j)
public abstract int limit()
public int find()
|
JML | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||