diff options
author | toma <toma@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2009-11-25 17:56:58 +0000 |
---|---|---|
committer | toma <toma@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2009-11-25 17:56:58 +0000 |
commit | bcb704366cb5e333a626c18c308c7e0448a8e69f (patch) | |
tree | f0d6ab7d78ecdd9207cf46536376b44b91a1ca71 /kopete/protocols/groupwise/libgroupwise/eventtransfer.cpp | |
download | tdenetwork-bcb704366cb5e333a626c18c308c7e0448a8e69f.tar.gz tdenetwork-bcb704366cb5e333a626c18c308c7e0448a8e69f.zip |
Copy the KDE 3.5 branch to branches/trinity for new KDE 3.5 features.
BUG:215923
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdenetwork@1054174 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kopete/protocols/groupwise/libgroupwise/eventtransfer.cpp')
-rw-r--r-- | kopete/protocols/groupwise/libgroupwise/eventtransfer.cpp | 145 |
1 files changed, 145 insertions, 0 deletions
diff --git a/kopete/protocols/groupwise/libgroupwise/eventtransfer.cpp b/kopete/protocols/groupwise/libgroupwise/eventtransfer.cpp new file mode 100644 index 00000000..06178f21 --- /dev/null +++ b/kopete/protocols/groupwise/libgroupwise/eventtransfer.cpp @@ -0,0 +1,145 @@ +/* + eventtransfer.cpp - Kopete Groupwise Protocol + + Copyright (c) 2004 SUSE Linux AG http://www.suse.com + + Kopete (c) 2002-2004 by the Kopete developers <kopete-devel@kde.org> + + ************************************************************************* + * * + * This library is free software; you can redistribute it and/or * + * modify it under the terms of the GNU Lesser General Public * + * License as published by the Free Software Foundation; either * + * version 2 of the License, or (at your option) any later version. * + * * + ************************************************************************* +*/ + +#include "eventtransfer.h" + +EventTransfer::EventTransfer( const Q_UINT32 eventType, const QString & source, QDateTime timeStamp ) + : Transfer(), m_eventType( eventType ), m_source( source ), m_timeStamp( timeStamp ) +{ + m_contentFlags |= ( EventType | Source | TimeStamp ); +} + + +EventTransfer::~EventTransfer() +{ +} + +// query contents + +bool EventTransfer::hasEventType() +{ + return ( m_contentFlags & EventType ); +} + +bool EventTransfer::hasSource() +{ + return ( m_contentFlags & Source ); +} + +bool EventTransfer::hasTimeStamp() +{ + return ( m_contentFlags & TimeStamp ); +} + +bool EventTransfer::hasGuid() +{ + return ( m_contentFlags & Guid ); +} + +bool EventTransfer::hasFlags() +{ + return ( m_contentFlags & Flags ); +} + +bool EventTransfer::hasMessage() +{ + return ( m_contentFlags & Message ); +} + +bool EventTransfer::hasStatus() +{ + return ( m_contentFlags & Status ); +} + +bool EventTransfer::hasStatusText() +{ + return ( m_contentFlags & StatusText ); +} + +// accessors + +int EventTransfer::eventType() +{ + return m_eventType; +} + +QString EventTransfer::source() +{ + return m_source; +} + +QDateTime EventTransfer::timeStamp() +{ + return m_timeStamp; +} + +GroupWise::ConferenceGuid EventTransfer::guid() +{ + return m_guid; +} + +Q_UINT32 EventTransfer::flags() +{ + return m_flags; +} + +QString EventTransfer::message() +{ + return m_message; +} + +Q_UINT16 EventTransfer::status() +{ + return m_status; +} + +QString EventTransfer::statusText() +{ + return m_statusText; +} + +// mutators +void EventTransfer::setGuid( const GroupWise::ConferenceGuid & guid ) +{ + m_contentFlags |= Guid; + m_guid = guid; +} + +void EventTransfer::setFlags( const Q_UINT32 flags ) +{ + m_contentFlags |= Flags; + m_flags = flags; +} + +void EventTransfer::setMessage( const QString & message ) +{ + m_contentFlags |= Message; + m_message = message; +} + +void EventTransfer::setStatus( const Q_UINT16 inStatus ) +{ + m_contentFlags |= Status; + m_status = inStatus; +} + +void EventTransfer::setStatusText( const QString & statusText ) +{ + m_contentFlags |= StatusText; + m_statusText = statusText; +} + |