summaryrefslogtreecommitdiff
path: root/noncore/net/opietooth/lib/services.cc
Unidiff
Diffstat (limited to 'noncore/net/opietooth/lib/services.cc') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/net/opietooth/lib/services.cc26
1 files changed, 12 insertions, 14 deletions
diff --git a/noncore/net/opietooth/lib/services.cc b/noncore/net/opietooth/lib/services.cc
index 93ee70a..23b760b 100644
--- a/noncore/net/opietooth/lib/services.cc
+++ b/noncore/net/opietooth/lib/services.cc
@@ -110,26 +110,24 @@ Services::Services(const Services& service ){
110Services::~Services(){ 110Services::~Services(){
111 111
112} 112}
113Services &Services::operator=( const Services& ser){ 113Services &Services::operator=( const Services& ser){
114 m_name = ser.m_name; 114 m_name = ser.m_name;
115 m_recHandle = ser.m_recHandle; 115 m_recHandle = ser.m_recHandle;
116 m_classList = ser.m_classList; 116 m_classIds = ser.m_classIds;
117 m_classId = ser.m_classId;
118 m_protocols = ser.m_protocols; 117 m_protocols = ser.m_protocols;
119 m_profiles = ser.m_profiles; 118 m_profiles = ser.m_profiles;
120 return *this; 119 return *this;
121} 120}
122bool operator==( const Services& one, 121bool operator==( const Services& one,
123 const Services& two){ 122 const Services& two){
124 if ( ( one.recHandle() == two.recHandle() ) && 123 if ( ( one.recHandle() == two.recHandle() ) &&
125 ( one.classIdListInt() == two.classIdListInt() ) &&
126 ( one.serviceName() == two.serviceName() ) && 124 ( one.serviceName() == two.serviceName() ) &&
127 ( one.classIdList() == two.classIdList() ) &&
128 ( one.protocolDescriptorList() == two.protocolDescriptorList() ) && 125 ( one.protocolDescriptorList() == two.protocolDescriptorList() ) &&
129 ( one.profileDescriptor() == two.profileDescriptor() ) ) 126 ( one.profileDescriptor() == two.profileDescriptor() )
127 /* ( one.classIdList() == two.classIdList() ) */ )
130 return true; 128 return true;
131 return false; 129 return false;
132} 130}
133QString Services::serviceName() const{ 131QString Services::serviceName() const{
134 return m_name; 132 return m_name;
135} 133}
@@ -139,23 +137,23 @@ void Services::setServiceName( const QString& service ){
139int Services::recHandle() const{ 137int Services::recHandle() const{
140 return m_recHandle; 138 return m_recHandle;
141} 139}
142void Services::setRecHandle( int handle){ 140void Services::setRecHandle( int handle){
143 m_recHandle = handle; 141 m_recHandle = handle;
144} 142}
145QString Services::classIdList() const{ 143QMap<int, QString> Services::classIdList()const {
146 return m_classList; 144 return m_classIds;
145};
146void Services::insertClassId( int id, const QString& str ) {
147 m_classIds.insert( id, str );
147} 148}
148void Services::setClassIdList( const QString& str){ 149void Services::removeClassId(int id) {
149 m_classList = str; 150 m_classIds.remove( id );
150} 151}
151int Services::classIdListInt() const{ 152void Services::clearClassId() {
152 return m_classId; 153 m_classIds.clear();
153}
154void Services::setClassIdList(int id){
155 m_classId = id;
156} 154}
157void Services::insertProtocolDescriptor( const ProtocolDescriptor& prot){ 155void Services::insertProtocolDescriptor( const ProtocolDescriptor& prot){
158 m_protocols.append( prot ); 156 m_protocols.append( prot );
159} 157}
160void Services::clearProtocolDescriptorList(){ 158void Services::clearProtocolDescriptorList(){
161 m_protocols.clear(); 159 m_protocols.clear();