Tariqa
3.0
|
Public Member Functions | |
__construct ($query, $config, $throw_errors=false) | |
translate () | |
fetchNews ($fetch_type=self::FETCH_TEXTXML) | |
fetchWebsite ($fetch_only_body=true) | |
Static Public Member Functions | |
static | fetchArticle ($id, $newsConfig, $fetch_type=self::FETCH_DOMDOCUMENT) |
Data Fields | |
const | FETCH_DOMDOCUMENT = 'dom' |
const | FETCH_TEXTXML = 'txt' |
const | FETCH_OBJECT = 'obj' |
Protected Member Functions | |
hasAccess ($user_groups) |
Base class for fetching the news results from any engine and from any source
__construct | ( | $ | query, |
$ | config, | ||
$ | throw_errors = false |
||
) |
Constructs the news adapter
newsQuery | $query | The query |
array | $config | The config array |
boolean | $throw_errors | If true, throw errors instead of returning a message [OPTIONAL] public |
static fetchArticle | ( | $ | id, |
$ | newsConfig, | ||
$ | fetch_type = self::FETCH_DOMDOCUMENT |
||
) | [static] |
Fetches one article
string | $id | The document id |
array | $newsConfig | The news configuration array |
string | $fetch_type | See the fetch constants [OPTIONAL] public |
fetchNews | ( | $ | fetch_type = self::FETCH_TEXTXML | ) |
Fetches the news results
boolean | $fetch_type | See the fetch constants [OPTIONAL] public |
fetchWebsite | ( | $ | fetch_only_body = true | ) |
Fetches a website content
boolean | $fetch_only_body | If true, fetches only the body [OPTIONAL] public |
hasAccess | ( | $ | user_groups | ) | [protected] |
Checks if an user has access rights
array | $user_groups | An array with the user groups protected |
translate | ( | ) |
Translate the query from unified query syntax to engine specific protected
const FETCH_DOMDOCUMENT = 'dom' |
const FETCH_OBJECT = 'obj' |
const FETCH_TEXTXML = 'txt' |