FastBroadcast ist the main class of the API.

It is a factory for other classes used by the library. If You recieve the objects from this class there will bo no need to include other files of the Library, because all required scriptfiles are loaded by the library.

usage:

// Access to FastBroadcast API-Classes
require_once dirname(__FILE__).'/lib/FastBroadcast.class.php';

// Get the HttpClient from the Factory
$httpClient = FastBroadcast::HttpClient();

// combine params to a valid API-Request
$params = array(
    'scenes'        => 'salsa',
    'catgroups'     => 'event',
    'period'        => 'week',
    'ccty'          => 'Hamburg',
    'responsegroup' => 'medium');

// Do the Request
$retcode = $httpClient->GetEventList( $params );

 Methods

APPID

APPID() : string

Returns

stringthe application ID

Create an Instance of FastBroadcastCalendarEvent

CreateEvent() : object

Returns

objectinstance of FastBroadcastCalendarEvent

Get The Last Error

GetLastError(string $message) : int

Parameters

$message

string

the errormessage

Returns

intretcode

Get The Last Errormessage.

GetLastErrorMessage() : string

This method shold only be used for small examples to easy access the message of an error

Returns

stringmessage

Give back an Instance of the HttpClient

HttpClient() : object

Returns

objectinstance of class FastBroadcastHttpClient

Register a translation function

RegisterTranslationFunction(mixed $func) : void

Parameters

$func

mixed

the name of the function as a string or an array width classname and methodname for static method calls

Set the Application ID

SetAPPID(string $app_id) : void

Parameters

$app_id

string

the application ID

Setting an Error

SetError(int $retcode, string $message) : int

Parameters

$retcode

int

the retcode

$message

string

the message

Returns

intthe given retcode

Translate a given String

Translate(string $str) : string

Parameters

$str

string

the string to translate

Returns

stringthe translated string on success otherwise the given string

Clone - This class is for static use only

__clone() 

Constructor - This class is for static use only

__construct() 

 Properties

 

the scheme unsually http://

$scheme 

 

A Translation function can be assigned with the Method RegisterTranslationFunction

$translation_function 

 

The Application ID

$app_id 

 

Array Handling

$error 

 Constants

 

DOWNLOAD_PATH

DOWNLOAD_PATH 

 

ERROR

ERROR 

 

Constants for API-Access

HOST 

 

IMAGE_PATH

IMAGE_PATH 

 

returncodes

NO_DATA_FOUND 

 

RPC_PATH

RPC_PATH 

 

SUCCESS

SUCCESS 

 

TIMEOUT

TIMEOUT 

 

Version

VERSION