|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectkorat.finitization.impl.ClassDomain
public class ClassDomain
| Field Summary | |
|---|---|
private Class<?> |
classOfObjects
|
protected Constructor |
constructor
|
protected boolean |
initialized
|
private boolean |
isomorphismCheck
|
(package private) int |
numOfObjects
|
private List<Object> |
objects
|
protected Object[] |
params
|
| Constructor Summary | |
|---|---|
ClassDomain(Class<?> classOfObjects)
|
|
ClassDomain(Class<?> classOfObjects,
int numOfObjects)
|
|
ClassDomain(String classOfObjectsName,
int numOfObjects)
Helper. |
|
| Method Summary | |
|---|---|
void |
addObject(Object o)
Add existing object into class domain. |
void |
addObjects(Collection col)
Add all objects of the existing collection to the class domain |
void |
addObjects(Object[] objs)
Add all objects of the existing array to the class domain |
private boolean |
checkObjIndex(int ind)
|
boolean |
contains(Object obj)
Checks whether the object obj is the member of this class domain |
private boolean |
defaultIsomorphismCheck(Class<?> clazz)
|
boolean |
equals(Object other)
|
String |
getClassNameOfObjects()
Returns the name of class type for this domain Equal to {IClassDomain}.getClassOfObjects.getName(); |
Class<?> |
getClassOfObjects()
Returns the Class object for elements of this Domain |
int |
getIndexOf(Object obj)
Returns index of object obj in this class domain |
Object |
getObject(int index)
Returns object stored at a given position inside the class domain |
List<Object> |
getObjects()
|
int |
getSize()
Returns number of objects in this class domain |
int |
hashCode()
|
void |
includeInIsomorphismCheck(boolean include)
If this option is set, the class domain will be included in isomorphism checking. |
void |
initialize()
Creates all uncreated objects. |
boolean |
isIncludedInIsomorphismChecking()
|
boolean |
isInitialized()
|
String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
private final Class<?> classOfObjects
private List<Object> objects
protected boolean initialized
int numOfObjects
protected Constructor constructor
protected Object[] params
private boolean isomorphismCheck
| Constructor Detail |
|---|
ClassDomain(Class<?> classOfObjects,
int numOfObjects)
classOfObjects - -
type of objects, has to be a Class object of a classnumOfObjects - -
number of objects of classOfObject type to be created
ClassDomain(String classOfObjectsName,
int numOfObjects)
throws ClassNotFoundException
classOfObjectsName - -
fully qualified name of the Class of the objectsnumOfObjects - -
number of objects to be created
ClassNotFoundException - -
throws if classOfObjectName is not validClassDomain(Class<?> classOfObjects)
| Method Detail |
|---|
private boolean checkObjIndex(int ind)
private boolean defaultIsomorphismCheck(Class<?> clazz)
public Class<?> getClassOfObjects()
IClassDomainClass object for elements of this Domain
getClassOfObjects in interface IClassDomainpublic String getClassNameOfObjects()
IClassDomain
Equal to {IClassDomain}.getClassOfObjects.getName();
getClassNameOfObjects in interface IClassDomainpublic int getSize()
IClassDomain
getSize in interface IClassDomainpublic void initialize()
className(ITester interface); constructor
Size and other properties of class domain should be set before
calling this method, through constructor or some specialized interface.
public boolean isInitialized()
public Object getObject(int index)
public List<Object> getObjects()
public int getIndexOf(Object obj)
obj in this class domain
public boolean contains(Object obj)
obj is the member of this class domain
public boolean equals(Object other)
equals in class Objectpublic int hashCode()
hashCode in class Objectpublic void includeInIsomorphismCheck(boolean include)
IClassDomainIf this option is set, the class domain will be included in isomorphism checking. It means, that in case where one object from this class domain is used as a value for some field, it and all objects from this class domain with lower indices, will not be used as a value for any other field in current candidate.
By default, all class domains are included in isomorphism checking
includeInIsomorphismCheck in interface IClassDomaininclude - -
true if the class domain should be included in isomorphism
checkingpublic boolean isIncludedInIsomorphismChecking()
isIncludedInIsomorphismChecking in interface IClassDomainpublic void addObject(Object o)
IClassDomaininitialize operation will not affect it.
addObject in interface IClassDomaino - -
object to be added, null is not allowedpublic void addObjects(Object[] objs)
IClassDomain
addObjects in interface IClassDomainobjs - -
array of objects, null is not allowedpublic void addObjects(Collection col)
IClassDomain
addObjects in interface IClassDomaincol - -
collection of objects, null is not allowedpublic String toString()
toString in class Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||