Feed
Implements \ArrayAccess, \CountableClass to encapsulate a feed for the Joomla Platform.
since |
3.1.4 |
---|---|
package |
Joomla CMS |
Methods
__get
Magic method to return values for feed properties.
__get(string name) : mixed
since |
3.1.4 |
---|
Arguments
- name
string
The name of the property.
Response
mixed
__set
Magic method to set values for feed properties.
__set(string name, mixed value) : void
since |
3.1.4 |
---|
Arguments
- name
string
The name of the property.- value
mixed
The value to set for the property.
addCategory
Method to add a category to the feed object.
addCategory(string name, string uri = '') : \Joomla\CMS\Feed\Feed
since |
3.1.4 |
---|
Arguments
- name
string
The name of the category to add.- uri
string
The optional URI for the category to add.
Response
\Joomla\CMS\Feed\Feed
addContributor
Method to add a contributor to the feed object.
addContributor(string name, string email, string uri = null, string type = null) : \Joomla\CMS\Feed\Feed
since |
3.1.4 |
---|
Arguments
- name
string
The full name of the person to add.string
The email address of the person to add.- uri
string
The optional URI for the person to add.- type
string
The optional type of person to add.
Response
\Joomla\CMS\Feed\Feed
addEntry
Method to add an entry to the feed object.
addEntry(\Joomla\CMS\Feed\FeedEntry entry) : \Joomla\CMS\Feed\Feed
since |
3.1.4 |
---|
Arguments
- entry
\Joomla\CMS\Feed\FeedEntry
The entry object to add.
Response
\Joomla\CMS\Feed\Feed
count
Returns a count of the number of entries in the feed.
count() : int
This method is here to implement the Countable interface. You can call it by doing count($feed) rather than $feed->count();
Response
int
number of entries in the feed.
offsetExists
Whether or not an offset exists. This method is executed when using isset() or empty() on objects implementing ArrayAccess.
offsetExists(mixed offset) : bool
see | \Joomla\CMS\Feed\ArrayAccess::offsetExists() |
---|---|
since |
3.1.4 |
Arguments
- offset
mixed
An offset to check for.
Response
bool
offsetGet
Returns the value at specified offset.
offsetGet(mixed offset) : mixed
see | \Joomla\CMS\Feed\ArrayAccess::offsetGet() |
---|---|
since |
3.1.4 |
Arguments
- offset
mixed
The offset to retrieve.
Response
mixed
The value at the offset.
offsetSet
Assigns a value to the specified offset.
offsetSet(mixed offset, \Joomla\CMS\Feed\FeedEntry value) : bool
see | \Joomla\CMS\Feed\ArrayAccess::offsetSet() |
---|---|
since |
3.1.4 |
throws |
|
Arguments
- offset
mixed
The offset to assign the value to.- value
\Joomla\CMS\Feed\FeedEntry
The JFeedEntry to set.
Response
bool
offsetUnset
Unsets an offset.
offsetUnset(mixed offset) : void
see | \Joomla\CMS\Feed\ArrayAccess::offsetUnset() |
---|---|
since |
3.1.4 |
Arguments
- offset
mixed
The offset to unset.
removeCategory
Method to remove a category from the feed object.
removeCategory(string name) : \Joomla\CMS\Feed\Feed
since |
3.1.4 |
---|
Arguments
- name
string
The name of the category to remove.
Response
\Joomla\CMS\Feed\Feed
removeContributor
Method to remove a contributor from the feed object.
removeContributor(\Joomla\CMS\Feed\FeedPerson contributor) : \Joomla\CMS\Feed\Feed
since |
3.1.4 |
---|
Arguments
- contributor
\Joomla\CMS\Feed\FeedPerson
The person object to remove.
Response
\Joomla\CMS\Feed\Feed
removeEntry
Method to remove an entry from the feed object.
removeEntry(\Joomla\CMS\Feed\FeedEntry entry) : \Joomla\CMS\Feed\Feed
since |
3.1.4 |
---|
Arguments
- entry
\Joomla\CMS\Feed\FeedEntry
The entry object to remove.
Response
\Joomla\CMS\Feed\Feed
reverseItems
Method to reverse the items if display is set to 'oldest first'
reverseItems() : \Joomla\CMS\Feed\Feed
since |
3.1.4 |
---|
Response
\Joomla\CMS\Feed\Feed
setAuthor
Shortcut method to set the author for the feed object.
setAuthor(string name, string email, string uri = null, string type = null) : \Joomla\CMS\Feed\Feed
since |
3.1.4 |
---|
Arguments
- name
string
The full name of the person to set.string
The email address of the person to set.- uri
string
The optional URI for the person to set.- type
string
The optional type of person to set.
Response
\Joomla\CMS\Feed\Feed