Vesna
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
Public Member Functions | Static Public Member Functions | Static Public Attributes | List of all members
DispatchingTextMessagesBusinessLogic Class Reference

#include <DispatchingTextMessagesBusinessLogic.h>

Inheritance diagram for DispatchingTextMessagesBusinessLogic:
Inheritance graph
[legend]
Collaboration diagram for DispatchingTextMessagesBusinessLogic:
Collaboration graph
[legend]

Public Member Functions

 DispatchingTextMessagesBusinessLogic ()
 
virtual ~DispatchingTextMessagesBusinessLogic ()
 
void OnNewPredefinedMessagesReceived (const PredefinedMessages &predefinedMessages, const DispatchingTextMessagesReceiver::ReceivedMessageNotificationType receivedMessageNotificationType)
 OnNewPredefinedMessagesReceived - methods stores new received predefined messages and ReceivedMessageNotificationType (this class is primary holder) More...
 
PredefinedMessages GetPredefinedMessages () const
 GetPredefinedMessages - predefined messages texts are used for option to predefine texts, which user can send to dispatching without need to manually edit text. More...
 
bool GetReadTextMessages (QList< TextMessage > &textMessagesList) const
 
bool GetUnreadTextMessages (QList< TextMessage > &textMessagesList) const
 
bool GetLastReceivedUnreadTextMessageToWriteAnswer (TextMessage &textMessage) const
 
bool GetAnsweredTextMessages (QList< TextMessage > &textMessagesList) const
 
bool GetUnreadTextMessageByMessageTimeAndID (const QDateTime &messageTime, const uint32_t messageID, QString &messageText, PredefinedMessages &messageAnswersMap) const
 
bool CreateTextMessageAnswerFile (const QString &messageText, const uint32_t messageID, const QDateTime messageTime) const
 CreateTextMessageAnswerFile - method creates and stores new file that represents text message that we sent to dispatching. More...
 
bool MoveUnreadTextMessageToReadMessagesDirectory (const QDateTime messageTime, const uint32_t messageID) const
 
bool DeleteTextMessage (const QDateTime messageTime, const uint32_t messageID, const bool isReceivedMessage)
 
DispatchingTextMessagesReceiver::ReceivedMessageNotificationType GetReceivedTextMessageNotificationType () const
 GetReceivedTextMessageNotificationType. More...
 
bool GetUnreadTextMessagesCount (int &unreadMessagesCount)
 
- Public Member Functions inherited from BusinessLogic
 BusinessLogic (ApplicationDefines::BusinessLogicType businessLogicType, ApplicationDefines::BusinessLogicLifeTimeType businessLogicLifeTimeType)
 
virtual ~BusinessLogic ()
 
ApplicationDefines::BusinessLogicType GetBusinessLogicType () const
 
ApplicationDefines::BusinessLogicLifeTimeType GetBusinessLogicLifeTimeType () const
 

Static Public Member Functions

static bool IsMessageCreatedOrAnsweredLater (const TextMessage &textMessage1, const TextMessage &textMessage2)
 
static bool IsMessageCreatedOrAnsweredEarlier (const TextMessage &textMessage1, const TextMessage &textMessage2)
 

Static Public Attributes

static const
ApplicationDefines::BusinessLogicType 
mBusinessLogicType = ApplicationDefines::DispatchingTextMessagesBusinessLogic
 

Constructor & Destructor Documentation

DispatchingTextMessagesBusinessLogic::DispatchingTextMessagesBusinessLogic ( )
DispatchingTextMessagesBusinessLogic::~DispatchingTextMessagesBusinessLogic ( )
virtual

Member Function Documentation

bool DispatchingTextMessagesBusinessLogic::CreateTextMessageAnswerFile ( const QString &  messageText,
const uint32_t  messageID,
const QDateTime  messageTime 
) const

CreateTextMessageAnswerFile - method creates and stores new file that represents text message that we sent to dispatching.

Parameters
messageText- sent message text
messageID- sent message ID
messageTime- message sent time
Returns
true on success, false on failure
bool DispatchingTextMessagesBusinessLogic::DeleteTextMessage ( const QDateTime  messageTime,
const uint32_t  messageID,
const bool  isReceivedMessage 
)
bool DispatchingTextMessagesBusinessLogic::GetAnsweredTextMessages ( QList< TextMessage > &  textMessagesList) const
bool DispatchingTextMessagesBusinessLogic::GetLastReceivedUnreadTextMessageToWriteAnswer ( TextMessage textMessage) const

Here is the call graph for this function:

PredefinedMessages DispatchingTextMessagesBusinessLogic::GetPredefinedMessages ( ) const

GetPredefinedMessages - predefined messages texts are used for option to predefine texts, which user can send to dispatching without need to manually edit text.

Returns
predefined messages map
bool DispatchingTextMessagesBusinessLogic::GetReadTextMessages ( QList< TextMessage > &  textMessagesList) const
DispatchingTextMessagesReceiver::ReceivedMessageNotificationType DispatchingTextMessagesBusinessLogic::GetReceivedTextMessageNotificationType ( ) const

GetReceivedTextMessageNotificationType.

Returns
- method returns if received text message should be displayed, should be displayed in some states or shouldn't be displayed at all
bool DispatchingTextMessagesBusinessLogic::GetUnreadTextMessageByMessageTimeAndID ( const QDateTime &  messageTime,
const uint32_t  messageID,
QString &  messageText,
PredefinedMessages messageAnswersMap 
) const

Here is the call graph for this function:

Here is the caller graph for this function:

bool DispatchingTextMessagesBusinessLogic::GetUnreadTextMessages ( QList< TextMessage > &  textMessagesList) const
bool DispatchingTextMessagesBusinessLogic::GetUnreadTextMessagesCount ( int &  unreadMessagesCount)
bool DispatchingTextMessagesBusinessLogic::IsMessageCreatedOrAnsweredEarlier ( const TextMessage textMessage1,
const TextMessage textMessage2 
)
static

Here is the caller graph for this function:

bool DispatchingTextMessagesBusinessLogic::IsMessageCreatedOrAnsweredLater ( const TextMessage textMessage1,
const TextMessage textMessage2 
)
static
bool DispatchingTextMessagesBusinessLogic::MoveUnreadTextMessageToReadMessagesDirectory ( const QDateTime  messageTime,
const uint32_t  messageID 
) const
void DispatchingTextMessagesBusinessLogic::OnNewPredefinedMessagesReceived ( const PredefinedMessages predefinedMessages,
const DispatchingTextMessagesReceiver::ReceivedMessageNotificationType  receivedMessageNotificationType 
)

OnNewPredefinedMessagesReceived - methods stores new received predefined messages and ReceivedMessageNotificationType (this class is primary holder)

Parameters
predefinedMessages- predefined messages map
receivedMessageNotificationType-
See also
enum ReceivedMessageNotificationType in class DispatchingTextMessagesReceiver

Member Data Documentation

const ApplicationDefines::BusinessLogicType DispatchingTextMessagesBusinessLogic::mBusinessLogicType = ApplicationDefines::DispatchingTextMessagesBusinessLogic
static

The documentation for this class was generated from the following files: