ClassClient Class
The ClassClient class provides a ROS service abstraction for classes exploration. More...
Header: | #include "ontologenius/clients/ontologyClients/ClassClient.h" |
Inherits: | OntologyClient |
Namespace: | onto |
Public Functions
ClassClient(const std::string& name) | |
std::vector<std::string> | getDown(const std::string& name, int depth = -1, const std::string& selector = "") |
std::vector<std::string> | getDisjoint(const std::string& name) |
std::vector<std::string> | getOn(const std::string& name, const std::string& property, const std::string& selector = "") |
std::vector<std::string> | getFrom(const std::string& property, const std::string& name, const std::string& selector = "") |
std::vector<std::string> | getWith(const std::string& name_1, const std::string& name_2, const std::string& selector = "", int depth = -1) |
std::vector<std::string> | getRelatedFrom(const std::string& property) |
std::vector<std::string> | getRelatedOn(const std::string& property) |
std::vector<std::string> | getRelatedWith(const std::string& name) |
std::vector<std::string> | getRelationFrom(const std::string& name, int depth = -1) |
std::vector<std::string> | getRelationOn(const std::string& name, int depth = -1) |
std::vector<std::string> | getRelationWith(const std::string& name) |
std::vector<std::string> | getDomainOf(const std::string& name, const std::string& selector = "", int depth = -1) |
std::vector<std::string> | getRangeOf(const std::string& name, const std::string& selector = "", int depth = -1) |
Reimplemented Public Functions
- 10 public functions inherited from OntologyClient
- 2 public functions inherited from ClientBase
Detailed Description
The ClassClient class provides an abstraction of ontologenius classes ROS service.
The ontologenius classes service allows the exploration of classes contained by ontologenius core.
This class is based on ClientBase and so ensure a persistent connection with ontologenius/class service. The persistent connection ensures a minimal response time. A reconnection logic is implemented in the event that the persistent connection fails.
See also IndividualClient, DataPropertyClient and ObjectPropertyClient.
Public Function Documentation
ClassClient::ClassClient(const std::string& name)
Constructs a class client.
Can be used in a multi-ontology mode by specifying the name of the ontology name. For classic use, name should be defined as "".
std::vector<std::string> ClassClient::getDown(const std::string& name, int depth = -1, const std::string& selector = "")
Gives all classes below the one given in the parameter: name.
The optional depth parameter can be set to limit tree propagation to a specific value. The default value -1 represents no propagation limitation.
The optional selector parameter can be set to only get results inheriting from the selector class. The default value "" represents no restriction on the result.
std::vector<std::string> ClassClient::getDisjoint(const std::string& name)
Gives all the disjoint classes of the one given in the parameter: name.
std::vector<std::string> ClassClient::getOn(const std::string& name, const std::string& property, const std::string& selector = "")
Gives all the classes pointed by the property property and applied to the class name.
The optional selector parameter can be set to only get results inheriting from the selector class. The default value "" represents no restriction on the result.
std::vector<std::string> ClassClient::getFrom(const std::string& property, const std::string& name, const std::string& selector = "")
Gives all the classes having the given property property and pointing to the class name.
The optional selector parameter can be set to only get results inheriting from the selector class. The default value "" represents no restriction on the result.
std::vector<std::string> ClassClient::getWith(const std::string& name_1, const std::string& name_2, const std::string& selector = "", int depth = -1)
Gives all the properties linking the two classes name_1 and name_2.
The optional selector parameter can be set to only get results inheriting from the selector property. The default value "" represents no restriction on the result.
The optional depth parameter can be set to limit tree propagation to a specific value. The default value -1 represents no propagation limitation.
std::vector<std::string> ClassClient::getRelatedFrom(const std::string& property)
Gives all the classes possessing the property property.
std::vector<std::string> ClassClient::getRelatedOn(const std::string& property)
Gives all the classes pointed to by the property property.
std::vector<std::string> ClassClient::getRelatedWith(const std::string& name)
Gives all the classes having a property pointing to the class name.
std::vector<std::string> ClassClient::getRelationFrom(const std::string& name, int depth = -1)
Gives all the properties applied to the class name.
The optional depth parameter can be set to limit tree propagation to a specific value. The default value -1 represents no propagation limitation.
std::vector<std::string> ClassClient::getRelationOn(const std::string& name, int depth = -1)
Gives all the properties going to the class name.
The optional depth parameter can be set to limit tree propagation to a specific value. The default value -1 represents no propagation limitation.
std::vector<std::string> ClassClient::getRelationWith(const std::string& name)
Gives all the classes pointed by a property applied to the class name.
std::vector<std::string> ClassClient::getDomainOf(const std::string& name, const std::string& selector = "", int depth = -1)
Gives all the properties for which the class name is part of the domain.
The optional selector parameter can be set to only get results inheriting from the selector property. The default value "" represents no restriction on the result.
The optional depth parameter can be set to limit tree propagation of the class to a specific value. The default value -1 represents no propagation limitation.
std::vector<std::string> ClassClient::getRangeOf(const std::string& name, const std::string& selector = "", int depth = -1)
Gives all the properties for which the class name is part of the range.
The optional selector parameter can be set to only get results inheriting from the selector property. The default value "" represents no restriction on the result.
The optional depth parameter can be set to limit tree propagation of the class to a specific value. The default value -1 represents no propagation limitation.