Moodle  2.2.1
http://www.collinsharper.com
Zend_Service_SlideShare Class Reference

Public Member Functions

 setHttpClient (Zend_Http_Client $client)
 getHttpClient ()
 setCacheObject (Zend_Cache_Core $cacheobject)
 getCacheObject ()
 getUserName ()
 setUserName ($un)
 getPassword ()
 setPassword ($pw)
 getApiKey ()
 setApiKey ($key)
 getSharedSecret ()
 setSharedSecret ($secret)
 __construct ($apikey, $sharedSecret, $username=null, $password=null)
 uploadSlideShow (Zend_Service_SlideShare_SlideShow $ss, $make_src_public=true)
 getSlideShow ($ss_id)
 getSlideShowsByUsername ($username, $offset=null, $limit=null)
 getSlideShowsByTag ($tag, $offset=null, $limit=null)
 getSlideShowsByGroup ($group, $offset=null, $limit=null)

Data Fields

const SERVICE_ERROR_BAD_APIKEY = 1
const SERVICE_ERROR_BAD_AUTH = 2
const SERVICE_ERROR_MISSING_TITLE = 3
const SERVICE_ERROR_MISSING_FILE = 4
const SERVICE_ERROR_EMPTY_TITLE = 5
const SERVICE_ERROR_NOT_SOURCEOBJ = 6
const SERVICE_ERROR_INVALID_EXT = 7
const SERVICE_ERROR_FILE_TOO_BIG = 8
const SERVICE_ERROR_SHOW_NOT_FOUND = 9
const SERVICE_ERROR_USER_NOT_FOUND = 10
const SERVICE_ERROR_GROUP_NOT_FOUND = 11
const SERVICE_ERROR_MISSING_TAG = 12
const SERVICE_ERROR_DAILY_LIMIT = 99
const SERVICE_ERROR_ACCOUNT_BLOCKED = 100
const SERVICE_UPLOAD_URI = 'http://www.slideshare.net/api/1/upload_slideshow'
const SERVICE_GET_SHOW_URI = 'http://www.slideshare.net/api/1/get_slideshow'
const SERVICE_GET_SHOW_BY_USER_URI = 'http://www.slideshare.net/api/1/get_slideshow_by_user'
const SERVICE_GET_SHOW_BY_TAG_URI = 'http://www.slideshare.net/api/1/get_slideshow_by_tag'
const SERVICE_GET_SHOW_BY_GROUP_URI = 'http://www.slideshare.net/api/1/get_slideshows_from_group'
const POWERPOINT_MIME_TYPE = "application/vnd.ms-powerpoint"

Protected Member Functions

 _getSlideShowsByType ($key, $value, $offset=null, $limit=null)
 _slideShowNodeToObject (SimpleXMLElement $node)

Protected Attributes

 $_apiKey
 $_sharedSecret
 $_username
 $_password
 $_httpclient
 $_cacheobject

Detailed Description

Definition at line 50 of file SlideShare.php.


Constructor & Destructor Documentation

__construct ( apikey,
sharedSecret,
username = null,
password = null 
)

The Constructor

Parameters:
string$apikeyThe API key
string$sharedSecretThe shared secret
string$usernameThe username
string$passwordThe password

Definition at line 291 of file SlideShare.php.

Here is the call graph for this function:


Member Function Documentation

_getSlideShowsByType ( key,
value,
offset = null,
limit = null 
) [protected]

Retrieves Zend_Service_SlideShare_SlideShow object arrays based on the type of list desired

Parameters:
string$keyThe type of slide show object to retrieve
string$valueThe specific search query for the slide show type to look up
int$offsetThe offset of the list to start retrieving from
int$limitThe maximum number of slide shows to retrieve
Returns:
array An array of Zend_Service_SlideShare_SlideShow objects

Definition at line 493 of file SlideShare.php.

Here is the call graph for this function:

Here is the caller graph for this function:

_slideShowNodeToObject ( SimpleXMLElement $  node) [protected]

Converts a SimpleXMLElement object representing a response from the service into a Zend_Service_SlideShare_SlideShow object

Parameters:
SimpleXMLElement$nodeThe input XML from the slideshare.net service
Returns:
Zend_Service_SlideShare_SlideShow The resulting object

Definition at line 585 of file SlideShare.php.

Here is the caller graph for this function:

getApiKey ( )

Gets the API key to be used in making API calls

Returns:
string the API Key

Definition at line 244 of file SlideShare.php.

Here is the caller graph for this function:

Gets the Zend_Cache object which will be used to cache API queries. If no cache object was previously set the the default will be used (Filesystem caching in /tmp with a life time of 43200 seconds)

Returns:
Zend_Cache_Core The object used in caching

Definition at line 181 of file SlideShare.php.

Here is the call graph for this function:

Here is the caller graph for this function:

Returns the instance of the Zend_Http_Client which will be used. Creates an instance of Zend_Http_Client if no previous client was set.

Returns:
Zend_Http_Client The HTTP client which will be used

Definition at line 147 of file SlideShare.php.

Here is the call graph for this function:

Here is the caller graph for this function:

Gets the password to use in API calls

Returns:
string the password to use in API calls

Definition at line 222 of file SlideShare.php.

Here is the caller graph for this function:

Gets the shared secret used in making API calls

Returns:
string the Shared secret

Definition at line 266 of file SlideShare.php.

Here is the caller graph for this function:

getSlideShow ( ss_id)

Retrieves a slide show's information based on slide show ID

Parameters:
int$ss_idThe slide show ID
Returns:
Zend_Service_SlideShare_SlideShow the Slideshow object

Definition at line 385 of file SlideShare.php.

Here is the call graph for this function:

getSlideShowsByGroup ( group,
offset = null,
limit = null 
)

Retrieves an array of slide shows based on group name

Parameters:
string$groupThe group name to retrieve slide shows for
int$offsetThe offset of the list to start retrieving from
int$limitThe maximum number of slide shows to retrieve
Returns:
array An array of Zend_Service_SlideShare_SlideShow objects

Definition at line 478 of file SlideShare.php.

Here is the call graph for this function:

getSlideShowsByTag ( tag,
offset = null,
limit = null 
)

Retrieves an array of slide shows based on tag

Parameters:
string$tagThe tag to retrieve slide shows with
int$offsetThe offset of the list to start retrieving from
int$limitThe maximum number of slide shows to retrieve
Returns:
array An array of Zend_Service_SlideShare_SlideShow objects

Definition at line 455 of file SlideShare.php.

Here is the call graph for this function:

getSlideShowsByUsername ( username,
offset = null,
limit = null 
)

Retrieves an array of slide shows for a given username

Parameters:
string$usernameThe username to retrieve slide shows from
int$offsetThe offset of the list to start retrieving from
int$limitThe maximum number of slide shows to retrieve
Returns:
array An array of Zend_Service_SlideShare_SlideShow objects

Definition at line 442 of file SlideShare.php.

Here is the call graph for this function:

Returns the user name used for API calls

Returns:
string The username

Definition at line 200 of file SlideShare.php.

Here is the caller graph for this function:

setApiKey ( key)

Sets the API key to be used in making API calls

Parameters:
string$keyThe API key to use
Returns:
Zend_Service_SlideShare

Definition at line 255 of file SlideShare.php.

Here is the caller graph for this function:

setCacheObject ( Zend_Cache_Core $  cacheobject)

Sets the Zend_Cache object to use to cache the results of API queries

Parameters:
Zend_Cache_Core$cacheobjectThe Zend_Cache object used
Returns:
Zend_Service_SlideShare

Definition at line 168 of file SlideShare.php.

Here is the caller graph for this function:

Sets the Zend_Http_Client object to use in requests. If not provided a default will be used.

Parameters:
Zend_Http_Client$clientThe HTTP client instance to use
Returns:
Zend_Service_SlideShare

Definition at line 135 of file SlideShare.php.

Here is the caller graph for this function:

setPassword ( pw)

Sets the password to use in API calls

Parameters:
string$pwThe password to use
Returns:
Zend_Service_SlideShare

Definition at line 233 of file SlideShare.php.

setSharedSecret ( secret)

Sets the shared secret used in making API calls

Parameters:
string$secretthe shared secret
Returns:
Zend_Service_SlideShare

Definition at line 277 of file SlideShare.php.

setUserName ( un)

Sets the user name to use for API calls

Parameters:
string$unThe username to use
Returns:
Zend_Service_SlideShare

Definition at line 211 of file SlideShare.php.

uploadSlideShow ( Zend_Service_SlideShare_SlideShow ss,
make_src_public = true 
)

Uploads the specified Slide show the the server

Parameters:
Zend_Service_SlideShare_SlideShow$ssThe slide show object representing the slide show to upload
boolean$make_src_publicDetermines if the the slide show's source file is public or not upon upload
Returns:
Zend_Service_SlideShare_SlideShow The passed Slide show object, with the new assigned ID provided

Definition at line 308 of file SlideShare.php.

Here is the call graph for this function:


Field Documentation

$_apiKey [protected]

Definition at line 91 of file SlideShare.php.

$_cacheobject [protected]

Definition at line 126 of file SlideShare.php.

$_httpclient [protected]

Definition at line 119 of file SlideShare.php.

$_password [protected]

Definition at line 112 of file SlideShare.php.

$_sharedSecret [protected]

Definition at line 98 of file SlideShare.php.

$_username [protected]

Definition at line 105 of file SlideShare.php.

const POWERPOINT_MIME_TYPE = "application/vnd.ms-powerpoint"

The MIME type of Slideshow files

Definition at line 84 of file SlideShare.php.

Definition at line 69 of file SlideShare.php.

Web service result code mapping

Definition at line 56 of file SlideShare.php.

Definition at line 57 of file SlideShare.php.

Definition at line 68 of file SlideShare.php.

Definition at line 60 of file SlideShare.php.

Definition at line 63 of file SlideShare.php.

Definition at line 66 of file SlideShare.php.

Definition at line 62 of file SlideShare.php.

Definition at line 59 of file SlideShare.php.

Definition at line 67 of file SlideShare.php.

Definition at line 58 of file SlideShare.php.

Definition at line 61 of file SlideShare.php.

Definition at line 64 of file SlideShare.php.

Definition at line 65 of file SlideShare.php.

const SERVICE_GET_SHOW_BY_GROUP_URI = 'http://www.slideshare.net/api/1/get_slideshows_from_group'

Definition at line 78 of file SlideShare.php.

const SERVICE_GET_SHOW_BY_TAG_URI = 'http://www.slideshare.net/api/1/get_slideshow_by_tag'

Definition at line 77 of file SlideShare.php.

const SERVICE_GET_SHOW_BY_USER_URI = 'http://www.slideshare.net/api/1/get_slideshow_by_user'

Definition at line 76 of file SlideShare.php.

const SERVICE_GET_SHOW_URI = 'http://www.slideshare.net/api/1/get_slideshow'

Definition at line 75 of file SlideShare.php.

const SERVICE_UPLOAD_URI = 'http://www.slideshare.net/api/1/upload_slideshow'

Slide share Web service communication URIs

Definition at line 74 of file SlideShare.php.


The documentation for this class was generated from the following file:
 All Data Structures Namespaces Files Functions Variables Enumerations