com.tencent.tcaplus.client
Interface Response


public interface Response

the response interface

Version:
Version 1.0
Author:
yahuiwang,elviszhu

Method Summary
 Record fetchRecord()
          get a record from the response
 int getAppId()
          get the appid
 int getCmd()
          get the operation type
 int getRecordCount()
          get the record num
 java.util.List<Record> getRecordList()
          get the record list from the response,used in batchget operation.
 int getResult()
          get the result
 int getResultFlag()
          get the result flag
 int getSequence()
          get the sequence
 java.lang.String getTableName()
          get the tableName
 byte[] getUserData()
          get the user defined data
 int getZoneId()
          get the zoneId
 java.lang.String toString()
          visualize the content
 

Method Detail

getTableName

java.lang.String getTableName()
                              throws com.tencent.tcaplus.util.TCaplusException
get the tableName

Returns:
String: the tableName
Throws:
com.tencent.tcaplus.util.TCaplusException

getResult

int getResult()
              throws com.tencent.tcaplus.util.TCaplusException
get the result

Returns:
int: 0 means suceess, the other means the error code.
Throws:
com.tencent.tcaplus.util.TCaplusException

getAppId

int getAppId()
             throws com.tencent.tcaplus.util.TCaplusException
get the appid

Returns:
int: the appid
Throws:
com.tencent.tcaplus.util.TCaplusException

getZoneId

int getZoneId()
              throws com.tencent.tcaplus.util.TCaplusException
get the zoneId

Returns:
int: the zoneId
Throws:
com.tencent.tcaplus.util.TCaplusException

getCmd

int getCmd()
           throws com.tencent.tcaplus.util.TCaplusException
get the operation type

Returns:
int: the operation type
Throws:
com.tencent.tcaplus.util.TCaplusException

getSequence

int getSequence()
get the sequence

Returns:
int: the sequence

getResultFlag

int getResultFlag()
                  throws com.tencent.tcaplus.util.TCaplusException
get the result flag

Returns:
int: the result flag
Throws:
com.tencent.tcaplus.util.TCaplusException

getUserData

byte[] getUserData()
                   throws com.tencent.tcaplus.util.TCaplusException
get the user defined data

Returns:
byte[]: the user defined data
Throws:
com.tencent.tcaplus.util.TCaplusException

getRecordCount

int getRecordCount()
                   throws com.tencent.tcaplus.util.TCaplusException
get the record num

Returns:
int: the record num
Throws:
com.tencent.tcaplus.util.TCaplusException

fetchRecord

Record fetchRecord()
get a record from the response

Returns:
Record: when used in get operation,the record means the result . when used in batchget operation, the record means the first record of the result.

getRecordList

java.util.List<Record> getRecordList()
                                     throws com.tencent.tcaplus.util.TCaplusException
get the record list from the response,used in batchget operation.

Returns:
List: the record list
Throws:
com.tencent.tcaplus.util.TCaplusException

toString

java.lang.String toString()
visualize the content

Overrides:
toString in class java.lang.Object
Returns:
String: the visualized string