Package org.jspace
Class FormalField
java.lang.Object
org.jspace.FormalField
- All Implemented Interfaces:
java.io.Serializable,TemplateField
public class FormalField extends java.lang.Object implements TemplateField
Identifies a formal template field.
- See Also:
- Serialized Form
-
Constructor Summary
Constructors Constructor Description FormalField(java.lang.Class<?> type)Creates a template field matching any value of typetype. -
Method Summary
Modifier and Type Method Description booleanequals(java.lang.Object obj)java.lang.Class<?>getFormalFieldType()inthashCode()booleanmatch(java.lang.Object o)Returnstrueif parametersois instance ofthis.type.java.lang.StringtoString()Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Constructor Details
-
FormalField
public FormalField(java.lang.Class<?> type)Creates a template field matching any value of typetype.- Parameters:
type- Class of expected field.
-
-
Method Details
-
match
public boolean match(java.lang.Object o)Returnstrueif parametersois instance ofthis.type.- Specified by:
matchin interfaceTemplateField- Parameters:
o- a generic object- Returns:
trueif the objectomatches against this field.- See Also:
org.pspaces.jspace.cmg.jresp.knowledge.TemplateField#match(java.lang.Object)
-
equals
public boolean equals(java.lang.Object obj)- Overrides:
equalsin classjava.lang.Object
-
hashCode
public int hashCode()- Overrides:
hashCodein classjava.lang.Object
-
toString
public java.lang.String toString()- Overrides:
toStringin classjava.lang.Object
-
getFormalFieldType
public java.lang.Class<?> getFormalFieldType()
-