OWLSExtensions.java revision 2
/*
* Created on Jan 6, 2005
*/
package examples;
/**
* An example demonstrating the extensibility features of the API.
*
* This example shows how the default Profile implementation can be extended to support
* custom defined extensions of the .
*
*
* @author Evren Sirin
*
*/
public class OWLSExtensions {
}
// register a converter for Owner class
// Override the default Profile converter to return ExtendedProfile descriptions
// Create a KB
// use a reasoner that will understand class and property inheritance
// Load an example service description
// Cast the profile to an ExtendedProfile (since default converter is overridden)
// Get the owner info
// Print the results
}
}
/**
* An extension to existing Profile implmentation to return contact information.
*
*/
public static class ExtendedProfile extends ProfileImpl {
/**
* Wrap the given OWLIndividual as a profile instance.
*
* @param ind
*/
super(ind);
}
/**
* Simply query the ontology for contactInformation property and cast the
* result to an Actor object.
*
* @return
*/
public OwnerEntity getOwner() {
}
}
/**
* A wrapper around an OWLIndividual that defines utility functions to access
* Owner information defined in FLA ontology.
*
*/
public static class OwnerEntity extends WrappedIndividual {
/**
* @param ind
*/
super(ind);
}
public String getEntityID() {
}
}
/**
* A simple converter that will wrap an existing OWLIndividual as an Actor objects. The
* individual should have rdf:type Actor triple in order the wrapping work. The convert
* function will automatically add this triple but should onyl be used if the ontology
* needs to be updated.
*
*/
public static class OwnerConverter implements OWLObjectConverter {
return (object instanceof OWLIndividual) &&
}
}
}
/**
* A simple converter that will wrap existing OWLIndividuals as ExtendedProfile objects.
* Very similar to the default Profile converter.
*
*/
public static class ExtendedProfileConverter implements OWLObjectConverter {
return (object instanceof OWLIndividual) &&
}
}
}
}
}