ILIAS
Release_4_0_x_branch Revision 61816
|
Base class for course/group mail notifications. More...
Public Member Functions | |
__construct () | |
Constructor. | |
setType ($a_type) | |
Set notification type. | |
getType () | |
Get notification type. | |
setSender ($a_usr_id) | |
Set sender of mail. | |
getSender () | |
get sender of mail | |
setRecipients ($a_rcp) | |
set mail recipients | |
getRecipients () | |
get array of recipients | |
setRefId ($a_id) | |
Set ref id. | |
getRefId () | |
get reference id | |
getObjId () | |
get object id | |
getObjType () | |
Get object type. | |
setAdditionalInformation ($a_info) | |
Additional information for creating notification mails. | |
getAdditionalInformation () | |
Get additional information for generating notification mails. | |
send () | |
Send notifications. | |
sendMail ($a_rcp, $a_type) | |
Send Mail. |
Data Fields | |
const | SUBJECT_TITLE_LENGTH = 60 |
Protected Member Functions | |
setSubject ($a_subject) | |
Set mail subject. | |
getSubject () | |
Get mail subject. | |
setBody ($a_body) | |
Set mail body. | |
appendBody ($a_body) | |
Append body text. | |
getBody () | |
Get body. | |
initLanguage ($a_usr_id) | |
Init language. | |
getLanguage () | |
get language object | |
getLanguageText ($a_keyword) | |
Replace new lines. | |
getObjectTitle ($a_shorten=false) | |
Get object title. | |
initMail () | |
Init mail. | |
getMail () | |
Get mail object. | |
createPermanentLink () | |
Create a permanent link for an object. | |
userToString ($a_usr_id) | |
Utility function. |
Private Attributes | |
$type = null | |
$sender = null | |
$mail = null | |
$subject = '' | |
$body = '' | |
$language = null | |
$recipients = array() | |
$ref_id = null | |
$obj_id = null | |
$obj_type = null | |
$additional_info = array() |
Base class for course/group mail notifications.
Definition at line 16 of file class.ilMailNotification.php.
ilMailNotification::__construct | ( | ) |
Constructor.
Reimplemented in ilCourseMembershipMailNotification, ilGroupMembershipMailNotification, and ilRegistrationMailNotification.
Definition at line 41 of file class.ilMailNotification.php.
References ilLanguageFactory\_getLanguage(), and setSender().
|
protected |
Append body text.
string | $a_body |
Definition at line 119 of file class.ilMailNotification.php.
Referenced by ilRegistrationMailNotification\send(), ilCourseMembershipMailNotification\send(), and ilGroupMembershipMailNotification\send().
|
protected |
Create a permanent link for an object.
Definition at line 319 of file class.ilMailNotification.php.
References ilLink\_getLink(), getObjType(), and getRefId().
Referenced by ilCourseMembershipMailNotification\send(), and ilGroupMembershipMailNotification\send().
ilMailNotification::getAdditionalInformation | ( | ) |
Get additional information for generating notification mails.
Definition at line 235 of file class.ilMailNotification.php.
References $additional_info.
Referenced by ilRegistrationMailNotification\send(), ilCourseMembershipMailNotification\send(), and ilGroupMembershipMailNotification\send().
|
protected |
Get body.
Definition at line 128 of file class.ilMailNotification.php.
References $body.
Referenced by sendMail().
|
protected |
get language object
Definition at line 167 of file class.ilMailNotification.php.
References $language.
Referenced by getLanguageText(), ilRegistrationMailNotification\initLanguage(), ilGroupMembershipMailNotification\initLanguage(), ilCourseMembershipMailNotification\initLanguage(), ilRegistrationMailNotification\send(), ilCourseMembershipMailNotification\send(), and ilGroupMembershipMailNotification\send().
|
protected |
Replace new lines.
object | $a_keyword |
Definition at line 177 of file class.ilMailNotification.php.
References getLanguage().
Referenced by ilCourseMembershipMailNotification\createCourseStatus(), ilGroupMembershipMailNotification\createGroupStatus(), ilRegistrationMailNotification\send(), ilGroupMembershipMailNotification\send(), and ilCourseMembershipMailNotification\send().
|
protected |
Get mail object.
Definition at line 310 of file class.ilMailNotification.php.
References initMail().
Referenced by ilRegistrationMailNotification\send(), ilGroupMembershipMailNotification\send(), ilCourseMembershipMailNotification\send(), and sendMail().
|
protected |
Get object title.
bool | shorten title |
Definition at line 245 of file class.ilMailNotification.php.
References ilObject\_lookupTitle(), getObjId(), and ilUtil\shortenText().
Referenced by ilCourseMembershipMailNotification\send(), and ilGroupMembershipMailNotification\send().
ilMailNotification::getObjId | ( | ) |
get object id
Definition at line 207 of file class.ilMailNotification.php.
References $obj_id.
Referenced by ilCourseMembershipMailNotification\createCourseStatus(), ilGroupMembershipMailNotification\createGroupStatus(), and getObjectTitle().
ilMailNotification::getObjType | ( | ) |
Get object type.
Definition at line 216 of file class.ilMailNotification.php.
References $obj_type.
Referenced by createPermanentLink().
ilMailNotification::getRecipients | ( | ) |
get array of recipients
Definition at line 147 of file class.ilMailNotification.php.
References $recipients.
Referenced by ilRegistrationMailNotification\send(), ilCourseMembershipMailNotification\send(), and ilGroupMembershipMailNotification\send().
ilMailNotification::getRefId | ( | ) |
get reference id
Definition at line 198 of file class.ilMailNotification.php.
References $ref_id.
Referenced by createPermanentLink().
ilMailNotification::getSender | ( | ) |
get sender of mail
Definition at line 80 of file class.ilMailNotification.php.
References $sender.
Referenced by initMail().
|
protected |
Get mail subject.
Definition at line 99 of file class.ilMailNotification.php.
References $subject.
Referenced by sendMail().
ilMailNotification::getType | ( | ) |
Get notification type.
Definition at line 61 of file class.ilMailNotification.php.
References $type.
Referenced by ilRegistrationMailNotification\send(), ilGroupMembershipMailNotification\send(), ilCourseMembershipMailNotification\send(), and send().
|
protected |
Init language.
int | $a_usr_id |
Reimplemented in ilCourseMembershipMailNotification, ilGroupMembershipMailNotification, and ilRegistrationMailNotification.
Definition at line 157 of file class.ilMailNotification.php.
References ilLanguageFactory\_getLanguageOfUser().
|
protected |
Init mail.
Definition at line 301 of file class.ilMailNotification.php.
References getSender().
Referenced by getMail(), ilRegistrationMailNotification\send(), ilCourseMembershipMailNotification\send(), and ilGroupMembershipMailNotification\send().
ilMailNotification::send | ( | ) |
Send notifications.
Reimplemented in ilCourseMembershipMailNotification, ilGroupMembershipMailNotification, and ilRegistrationMailNotification.
Definition at line 259 of file class.ilMailNotification.php.
References getType().
ilMailNotification::sendMail | ( | $a_rcp, | |
$a_type | |||
) |
Send Mail.
array | recipients |
array | mail type (one 'normal', 'system', 'email') |
Definition at line 273 of file class.ilMailNotification.php.
References $error, $GLOBALS, $recipients, ilObjUser\_lookupLogin(), getBody(), getMail(), and getSubject().
Referenced by ilRegistrationMailNotification\send(), ilCourseMembershipMailNotification\send(), and ilGroupMembershipMailNotification\send().
ilMailNotification::setAdditionalInformation | ( | $a_info | ) |
Additional information for creating notification mails.
array | $a_info |
Definition at line 226 of file class.ilMailNotification.php.
|
protected |
Set mail body.
string | $a_body |
Definition at line 109 of file class.ilMailNotification.php.
Referenced by ilRegistrationMailNotification\send(), ilCourseMembershipMailNotification\send(), and ilGroupMembershipMailNotification\send().
ilMailNotification::setRecipients | ( | $a_rcp | ) |
set mail recipients
array | $a_rcp | user ids |
Definition at line 138 of file class.ilMailNotification.php.
ilMailNotification::setRefId | ( | $a_id | ) |
Set ref id.
int | $a_id |
Definition at line 187 of file class.ilMailNotification.php.
References ilObject\_lookupObjId(), and ilObject\_lookupType().
ilMailNotification::setSender | ( | $a_usr_id | ) |
Set sender of mail.
int | $a_usr_id |
Definition at line 71 of file class.ilMailNotification.php.
Referenced by __construct().
|
protected |
Set mail subject.
string | $a_subject |
Definition at line 90 of file class.ilMailNotification.php.
Referenced by ilRegistrationMailNotification\send(), ilCourseMembershipMailNotification\send(), and ilGroupMembershipMailNotification\send().
ilMailNotification::setType | ( | $a_type | ) |
Set notification type.
int | $a_type |
Definition at line 52 of file class.ilMailNotification.php.
|
protected |
Utility function.
int | $a_usr_id |
Definition at line 339 of file class.ilMailNotification.php.
References $name, and ilObjUser\_lookupName().
Referenced by ilCourseMembershipMailNotification\send(), and ilGroupMembershipMailNotification\send().
|
private |
Definition at line 35 of file class.ilMailNotification.php.
Referenced by getAdditionalInformation().
|
private |
Definition at line 25 of file class.ilMailNotification.php.
Referenced by ilCourseMembershipMailNotification\createCourseStatus(), ilGroupMembershipMailNotification\createGroupStatus(), and getBody().
|
private |
Definition at line 27 of file class.ilMailNotification.php.
Referenced by getLanguage().
|
private |
Definition at line 23 of file class.ilMailNotification.php.
|
private |
Definition at line 32 of file class.ilMailNotification.php.
Referenced by getObjId().
|
private |
Definition at line 33 of file class.ilMailNotification.php.
Referenced by getObjType().
|
private |
Definition at line 29 of file class.ilMailNotification.php.
Referenced by getRecipients(), and sendMail().
|
private |
Definition at line 31 of file class.ilMailNotification.php.
Referenced by getRefId().
|
private |
Definition at line 21 of file class.ilMailNotification.php.
Referenced by getSender().
|
private |
Definition at line 24 of file class.ilMailNotification.php.
Referenced by getSubject().
|
private |
Definition at line 20 of file class.ilMailNotification.php.
Referenced by getType().
const ilMailNotification::SUBJECT_TITLE_LENGTH = 60 |
Definition at line 18 of file class.ilMailNotification.php.