Subversion Repositories SmartDukaan

Rev

Go to most recent revision | Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
155 ashish 1
'''
2
Created on 17-May-2010
3
 
4
@author: ashish
5
'''
6
from thrift.transport import TSocket
7
from thrift.transport.TTransport import TFramedTransport
8
from thrift.protocol.TBinaryProtocol import TBinaryProtocol
9
 
10
class BasicClient:
11
 
12
 
13
    def initialize(self, host , port):
14
        self.host = host
15
        self.port = port
16
        self.__start()
17
 
18
    def __start(self):
19
        self.transport = TSocket.TSocket(self.host, self.port)
20
        self.transport = TFramedTransport(self.transport)
21
        self.protocol = TBinaryProtocol(self.transport)
22
 
23