![]() |
Antidot PHP API
version 0.16.0
##PHP API to simplify integration of Antidot components
|
Concept item. More...
Public Member Functions | |
__construct ($item, $concepts) | |
Constructs new concept item. | |
get_text () | |
Retrieves text of the item. | |
has_concept () | |
Check whether current item has a concept. | |
get_data () | |
Retrieves concept data associated to current item. |
Concept item.
Concept results are made of one or more concept items. Concept items can have no data, one data or even multiple data attached to them.
__construct | ( | $item, | |
$concepts | |||
) |
Constructs new concept item.
$item | [in] new values to initialize the instance with. |
$concepts | [in] buffer of concept data (read only). |
Exception | when invalid/unrecognized data has been provided. |
get_data | ( | ) |
Retrieves concept data associated to current item.
Data are store as key/value pairs. Keys correspond to the URI of the concept. Values correspond to XML data of the concept.
null
when no concept matches the item text. get_text | ( | ) |
Retrieves text of the item.
has_concept | ( | ) |
Check whether current item has a concept.
For multi-words queries, no, one or more words can match one or more concepts. So, this method allow to check whether current item has binded concept(s) or not.
True
when current item has at least one binded concept, false
otherwise.