summaryrefslogtreecommitdiff
path: root/protocols/Xfire/src/variablevalue.h
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2015-08-11 13:33:42 +0000
committerGeorge Hazan <george.hazan@gmail.com>2015-08-11 13:33:42 +0000
commit85bd008c039eb1d93894e94fba9d158a42a71a12 (patch)
tree2d72d10759f6928e9e4b960175d2de01b5cf7e12 /protocols/Xfire/src/variablevalue.h
parent222802c2986dcaf029fdfb828b7679bdabfa7bb2 (diff)
massive code cleaning
git-svn-id: http://svn.miranda-ng.org/main/trunk@14910 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/Xfire/src/variablevalue.h')
-rw-r--r--protocols/Xfire/src/variablevalue.h66
1 files changed, 32 insertions, 34 deletions
diff --git a/protocols/Xfire/src/variablevalue.h b/protocols/Xfire/src/variablevalue.h
index 8282f47cbf..29e12743cb 100644
--- a/protocols/Xfire/src/variablevalue.h
+++ b/protocols/Xfire/src/variablevalue.h
@@ -20,45 +20,43 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#include <string>
-
#ifndef __VARIABVLEVALUE_H
#define __VARIABVLEVALUE_H
namespace xfirelib {
-class VariableValue {
- public:
- VariableValue();
- ~VariableValue();
-
- void setName(std::string name);
- void setValueLength(int valueLength);
- void setValue( char * value );
- void setValue( std::string value );
- void setValue( const char *value, int valueLength );
- void setValueFromLong( long value, int bytes );
- std::string getName();
- int getValueLength();
- char* getValue();
-
- int readName(char *packet, int index);
- int readValue(char *packet, int index, int length = -1, int ignoreZeroAfterLength = 0);
- int readVariableValue(char *packet, int index, int packetLength);
- /*TODO: disabled because of a bug in this method*/
- //int VariableValue::readFixValue(char *packet, int index, int packetLength, int valueLength);
-
- int writeName(char *buf, int index);
- int writeValue(char *buf, int index);
-
- long getValueAsLong();
- private:
- long myPow(int x, int y);
-
- std::string name;
- char *value;
- int valueLength;
-};
+ class VariableValue {
+ public:
+ VariableValue();
+ ~VariableValue();
+
+ void setName(std::string name);
+ void setValueLength(int valueLength);
+ void setValue( char * value );
+ void setValue( std::string value );
+ void setValue( const char *value, int valueLength );
+ void setValueFromLong( long value, int bytes );
+ std::string getName();
+ int getValueLength();
+ char* getValue();
+
+ int readName(char *packet, int index);
+ int readValue(char *packet, int index, int length = -1, int ignoreZeroAfterLength = 0);
+ int readVariableValue(char *packet, int index, int packetLength);
+ /*TODO: disabled because of a bug in this method*/
+ //int VariableValue::readFixValue(char *packet, int index, int packetLength, int valueLength);
+
+ int writeName(char *buf, int index);
+ int writeValue(char *buf, int index);
+
+ long getValueAsLong();
+ private:
+ long myPow(int x, int y);
+
+ std::string name;
+ char *value;
+ int valueLength;
+ };
};