Interface Inx_Api_List_ListContext

Description

An Inx_Api_List_ListContext corresponds to a list in Inxmail, like a mailing list or the system list.

An Inx_Api_List_ListContext corresponds to a list in Inxmail, like a mailing list or the system list. The Inx_Api_List_ListContextManager is used to access and manipulate these lists. A list is, in simple terms, a set of recipients for which mailings can be created. A list may offer various features (corresponding to agents in inxmail) which can be used to perform tasks like subscription management, creating text modules, generating reports, etc.

The available features can be determined from the Inx_Api_Features<i> interface. Using the constants defined in that interface, you can enable or disable features. The following snippet enables the subscription feature, if it is not already enabled: <pre> $oListContext = ... if(!$oListContext->isFeatureEnabled(Inx_Api_Features::SUBSCRIPTION_FEATURE_ID)) { $oListContext->enableFeature(Inx_Api_Features::SUBSCRIPTION_FEATURE_ID); } </pre> Be aware that not all features can be enabled for all lists. Which features can be enabled for which lists is also documented in the <i>Inx_Api_Features interface.

An Inx_Api_List_ListContext can also be used to retrieve the list properties using the findProperty($sPropertyName) and selectProperties() methods. These properties define the behaviour of the list. For more information on properties, see the Inx_Api_Property_Property documentation.

For an example on how to create and retrieve lists, see the Inx_Api_List_ListContextManager documentation.

Located in /Api/List/ListContext.php (line 45)

Inx_Api_BusinessObject
   |
   --Inx_Api_List_ListContext
Direct descendents
Class Description
Inx_Api_List_AdminListContext The Inx_Api_List_AdminListContext does not represent a usual mailing list.
Inx_Api_List_FilterListContext An Inx_Api_List_FilterListContext represents a mailing list with no permanent recipients.
Inx_Api_List_StandardListContext An Inx_Api_List_StandardListContext represents a normal mailing list.
Inx_Api_List_SystemListContext The Inx_Api_List_SystemListContext does not represent a usual mailing list.
Class Constant Summary
Method Summary
bool disableFeature (int $iFeatureId)
bool enableFeature (int $iFeatureId)
Inx_Api_Property_Property findProperty (string $sPropertyName)
string getDescription ()
Inx_Api_List_ListSize getListSize ([bool $computeNow = false])
string getName ()
bool isFeatureEnabled (int $iFeatureId)
void updateDescription (string $sDesc)
Methods
disableFeature (line 150)

Disables the feature with the given id.

Disables the feature with the given id.

  • return: true, if the feature has been disabled, false, if the feature was already disabled.
  • see: Inx_Api_Features
  • throws: Inx_Api_FeatureNotAvailableException if the feature is not available for this list.
  • access: public
bool disableFeature (int $iFeatureId)
  • int $iFeatureId: the id of the feature to disable.
enableFeature (line 139)

Enables the feature with the given id.

Enables the feature with the given id. Not every feature is accessible for every type of list. For example, the "Subscription" feature is available in standard lists, only. The "Mailing" feature can be used in standard and filter lists.

  • return: true, if the feature has been enabled, false, if the feature was already enabled.
  • see: Inx_Api_Features
  • throws: Inx_Api_FeatureNotAvailableException if the feature is not available for this list.
  • access: public
bool enableFeature (int $iFeatureId)
  • int $iFeatureId: the id of the feature to enable.
findProperty (line 106)

Returns the property identified by the specified name.

Returns the property identified by the specified name.

  • return: the property identified by the specified name.
  • see: Inx_Api_Property_PropertyNames
  • throws: Inx_Api_IllegalArgumentException if the property name is unknown.
  • access: public
Inx_Api_Property_Property findProperty (string $sPropertyName)
  • string $sPropertyName: the name of the property to be retrieved.
getCreationDatetime (line 87)

Returns the creation datetime.

Returns the creation datetime.

  • return: the creation datetime. The creation datetime is returned as ISO 8601 formatted datetime string.
  • access: public
string getCreationDatetime ()
getDescription (line 79)

Returns the list description.

Returns the list description.

  • return: the list description
  • access: public
string getDescription ()
getListSize (line 163)

Returns the number of recipients that are subscribed to the list.

Returns the number of recipients that are subscribed to the list. This method can return the actual list size if the parameter is true. Note: Refreshing the list size can produce a high load on the Inxmail Server. USE THIS METHOD WITH CAUTION!

  • return: the list size object.
  • throws: Inx_Api_DataException if the list is deleted.
  • access: public
Inx_Api_List_ListSize getListSize ([bool $computeNow = false])
  • bool $computeNow:
    1. true
    if the number of recipients shall be recomputed,
    1. false
    otherwise. May be ommitted (defaults to false).
getName (line 71)

Returns the list name. The names of the system and administration lists are predefined and immutable.

Returns the list name. The list names are unique, while the characters are case insensitive.
The names of the system and administration lists are predefined and immutable.

string getName ()
isFeatureEnabled (line 126)

Checks if the specified feature is enabled.

Checks if the specified feature is enabled.

  • return: true, if the feature is enabled, false otherwise.
  • see: Inx_Api_Features
  • throws: Inx_Api_FeatureNotAvailableException if the feature is not available for this list.
  • access: public
bool isFeatureEnabled (int $iFeatureId)
  • int $iFeatureId: the id of the feature to check.
selectProperties (line 115)

Returns an Inx_Api_BOResultSet containing all properties of this list.

Returns an Inx_Api_BOResultSet containing all properties of this list.

Inx_Api_BOResultSet selectProperties ()
updateDescription (line 95)

Changes the list description.

Changes the list description.

  • access: public
void updateDescription (string $sDesc)
  • string $sDesc: the new list description.

Inherited Methods

Inherited From Inx_Api_BusinessObject

Inx_Api_BusinessObject::commitUpdate()
Inx_Api_BusinessObject::getId()
Inx_Api_BusinessObject::reload()
Class Constants
ATTRIBUTE_DESCRIPTION = 2 (line 60)

Constant for the description attribute.

Constant for the description attribute. Used by the Inx_Api_UpdateException to indicate the error source.

ATTRIBUTE_NAME = 1 (line 53)

Constant for the name attribute.

Constant for the name attribute. Used by the Inx_Api_UpdateException to indicate the error source.

Documentation generated on Thu, 17 Sep 2015 14:27:26 +0200 by phpDocumentor 1.3.2