UNB Components Code Reference

UnbMessage::GetLatestReply method

Gets the latest message from all messages that are directly or indirectly referencing to this message through their primary reference.

public function UnbMessage::GetLatestReply ($includeCount = false);

Parameters

includeCount  –  optional, default: false

(bool) true to also return the total number of replies, see CountReplies

Return value

(UnbMessage) The message instance of the latest reply according to its CreatedTime, if includeCount is false.
(array(UnbMessage, int)) The message and the number of replies as array, if includeCount is true.

Remarks

TODO: Primary reference loop detection, throw UnbDatabaseException like in GetRefDEP() TODO: Don't do SELECT * but all required columns instead; maybe only some first, then all for the final record.

Member of class: UnbMessage

Implementation file: message.class.php, line 1501

© 2011 Yves Goergen. UNB Components Homepage. Reference generated on 2011-02-22.