Constructs an array of Picasa_Comment objects based on the XML taken from either the $xml parameter or from the contents of $url.
static
array
getCommentArray
([string $url = null], [ $xml = null], [array $contextArray = null], [boolean $useCache = true])
-
string
$url: A URL pointing to a Picasa Atom feed that has zero or more "entry" nodes represeing a Picasa comment. Optional, the default is null. If this parameter is null, the method will try to get the XML content from the $xml parameter directly.
-
SimpleXMLElement
$xml: XML from a Picasa Atom feed that has zero or more "entry" nodes represeing a Picasa comment. Optional, the default is null. If the $url parameter is null and the $xml parameter is null, a {@Picasa_Exception} is thrown.
-
array
$contextArray: An array that can be passed to stream_context_create() to generate a PHP context. See http://us2.php.net/manual/en/function.stream-context-create.php
-
boolean
$useCache: You can decide not to cache a specific request by passing false here. You may want to do this, for instance, if you're requesting a private feed.
Constructs a Picasa_Comment object from XML.
You'll notice that the parameters are in a different order than with other similar classes in the API. This is because it was initially created without a $url or $contextArray parameter and to maintain backwards compatibility, the two extra parameters had to be appended to the end.
Picasa_Comment
__construct
([ $comments = null], [string $url = null], [array $contextArray = null], [boolean $useCache = true])
-
SimpleXMLElement
$comments: XML representing a Picasa comment.
-
string
$url: A URL pointing to the Atom feed for the requested data. Optional, the default is null. If null is passed, the method assumes that the XML is supplied in the $comments parameter.
-
array
$contextArray: An array that can be passed to stream_context_create() to generate a PHP context. See http://us2.php.net/manual/en/function.stream-context-create.php
-
boolean
$useCache: You can decide not to cache a specific request by passing false here. You may want to do this, for instance, if you're requesting a private feed.
void
setAccountName
(string $accountName)
void
setAlbumid
(string $albumid)
void
setContent
(string $content)
void
setIdnum
(string $idnum)
void
setPhotoid
(id $photoidid)
void
setPublished
(string $published)
void
setTitle
(string $title)
void
setUpdated
(string $updated)
Constructs a textual representation of the current Picasa_Comment instantiation.
string
__toString
()