public class BCReflectiveIntrospector extends ReflectiveIntrospector
ReflectiveIntrospector
does, but
it assumes the accessors methods for aggregate slots to be in the
"old JADE style" i.e.
For every aggregate slot named XXX
,
with elements of type T
, the Java class must have
two accessible methods, with the following signature:
Iterator getAllXXX()
void addXXX(T t)
Constructor and Description |
---|
BCReflectiveIntrospector() |
Modifier and Type | Method and Description |
---|---|
void |
checkClass(ObjectSchema schema,
java.lang.Class javaClass,
Ontology onto)
Check the structure of a java class associated to an ontological element
to ensure that translations to/from abstract descriptors and java objects
(instances of that class) can be accomplished by this introspector.
|
AbsAggregate |
externalizeAggregate(java.lang.String slotName,
java.lang.Object obj,
ObjectSchema schema,
Ontology referenceOnto) |
java.lang.Object |
getSlotValue(java.lang.String slotName,
java.lang.Object obj,
ObjectSchema schema) |
java.lang.Object |
internalizeAggregate(java.lang.String slotName,
AbsAggregate abs,
ObjectSchema schema,
Ontology referenceOnto) |
protected boolean |
isAggregateObject(java.lang.Object obj) |
void |
setSlotValue(java.lang.String slotName,
java.lang.Object slotValue,
java.lang.Object obj,
ObjectSchema schema) |
externalizeSpecialType, internalizeSpecialType
protected boolean isAggregateObject(java.lang.Object obj)
public java.lang.Object getSlotValue(java.lang.String slotName, java.lang.Object obj, ObjectSchema schema) throws OntologyException
getSlotValue
in interface Introspector
getSlotValue
in class ReflectiveIntrospector
OntologyException
public void setSlotValue(java.lang.String slotName, java.lang.Object slotValue, java.lang.Object obj, ObjectSchema schema) throws OntologyException
setSlotValue
in interface Introspector
setSlotValue
in class ReflectiveIntrospector
OntologyException
public void checkClass(ObjectSchema schema, java.lang.Class javaClass, Ontology onto) throws OntologyException
checkClass
in interface Introspector
checkClass
in class ReflectiveIntrospector
schema
- The schema of the ontological elementjavaClass
- The java class associated to the ontologcal elementonto
- The Ontology that uses this IntrospectorOntologyException
- if the java class does not have the correct
structurepublic AbsAggregate externalizeAggregate(java.lang.String slotName, java.lang.Object obj, ObjectSchema schema, Ontology referenceOnto) throws OntologyException
externalizeAggregate
in interface Introspector
externalizeAggregate
in class ReflectiveIntrospector
OntologyException
public java.lang.Object internalizeAggregate(java.lang.String slotName, AbsAggregate abs, ObjectSchema schema, Ontology referenceOnto) throws OntologyException
internalizeAggregate
in interface Introspector
internalizeAggregate
in class ReflectiveIntrospector
OntologyException