lib/thrift/hbase.rb in hbaserb-0.0.4 vs lib/thrift/hbase.rb in hbaserb-0.0.5
- old
+ new
@@ -1,7 +1,7 @@
#
-# Autogenerated by Thrift
+# Autogenerated by Thrift Compiler (0.8.0)
#
# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
#
require 'thrift'
@@ -281,10 +281,74 @@
return result.success unless result.success.nil?
raise result.io unless result.io.nil?
raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'getRowWithColumnsTs failed: unknown result')
end
+ def getRows(tableName, rows)
+ send_getRows(tableName, rows)
+ return recv_getRows()
+ end
+
+ def send_getRows(tableName, rows)
+ send_message('getRows', GetRows_args, :tableName => tableName, :rows => rows)
+ end
+
+ def recv_getRows()
+ result = receive_message(GetRows_result)
+ return result.success unless result.success.nil?
+ raise result.io unless result.io.nil?
+ raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'getRows failed: unknown result')
+ end
+
+ def getRowsWithColumns(tableName, rows, columns)
+ send_getRowsWithColumns(tableName, rows, columns)
+ return recv_getRowsWithColumns()
+ end
+
+ def send_getRowsWithColumns(tableName, rows, columns)
+ send_message('getRowsWithColumns', GetRowsWithColumns_args, :tableName => tableName, :rows => rows, :columns => columns)
+ end
+
+ def recv_getRowsWithColumns()
+ result = receive_message(GetRowsWithColumns_result)
+ return result.success unless result.success.nil?
+ raise result.io unless result.io.nil?
+ raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'getRowsWithColumns failed: unknown result')
+ end
+
+ def getRowsTs(tableName, rows, timestamp)
+ send_getRowsTs(tableName, rows, timestamp)
+ return recv_getRowsTs()
+ end
+
+ def send_getRowsTs(tableName, rows, timestamp)
+ send_message('getRowsTs', GetRowsTs_args, :tableName => tableName, :rows => rows, :timestamp => timestamp)
+ end
+
+ def recv_getRowsTs()
+ result = receive_message(GetRowsTs_result)
+ return result.success unless result.success.nil?
+ raise result.io unless result.io.nil?
+ raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'getRowsTs failed: unknown result')
+ end
+
+ def getRowsWithColumnsTs(tableName, rows, columns, timestamp)
+ send_getRowsWithColumnsTs(tableName, rows, columns, timestamp)
+ return recv_getRowsWithColumnsTs()
+ end
+
+ def send_getRowsWithColumnsTs(tableName, rows, columns, timestamp)
+ send_message('getRowsWithColumnsTs', GetRowsWithColumnsTs_args, :tableName => tableName, :rows => rows, :columns => columns, :timestamp => timestamp)
+ end
+
+ def recv_getRowsWithColumnsTs()
+ result = receive_message(GetRowsWithColumnsTs_result)
+ return result.success unless result.success.nil?
+ raise result.io unless result.io.nil?
+ raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'getRowsWithColumnsTs failed: unknown result')
+ end
+
def mutateRow(tableName, row, mutations)
send_mutateRow(tableName, row, mutations)
recv_mutateRow()
end
@@ -748,10 +812,54 @@
result.io = io
end
write_result(result, oprot, 'getRowWithColumnsTs', seqid)
end
+ def process_getRows(seqid, iprot, oprot)
+ args = read_args(iprot, GetRows_args)
+ result = GetRows_result.new()
+ begin
+ result.success = @handler.getRows(args.tableName, args.rows)
+ rescue Apache::Hadoop::Hbase::Thrift::IOError => io
+ result.io = io
+ end
+ write_result(result, oprot, 'getRows', seqid)
+ end
+
+ def process_getRowsWithColumns(seqid, iprot, oprot)
+ args = read_args(iprot, GetRowsWithColumns_args)
+ result = GetRowsWithColumns_result.new()
+ begin
+ result.success = @handler.getRowsWithColumns(args.tableName, args.rows, args.columns)
+ rescue Apache::Hadoop::Hbase::Thrift::IOError => io
+ result.io = io
+ end
+ write_result(result, oprot, 'getRowsWithColumns', seqid)
+ end
+
+ def process_getRowsTs(seqid, iprot, oprot)
+ args = read_args(iprot, GetRowsTs_args)
+ result = GetRowsTs_result.new()
+ begin
+ result.success = @handler.getRowsTs(args.tableName, args.rows, args.timestamp)
+ rescue Apache::Hadoop::Hbase::Thrift::IOError => io
+ result.io = io
+ end
+ write_result(result, oprot, 'getRowsTs', seqid)
+ end
+
+ def process_getRowsWithColumnsTs(seqid, iprot, oprot)
+ args = read_args(iprot, GetRowsWithColumnsTs_args)
+ result = GetRowsWithColumnsTs_result.new()
+ begin
+ result.success = @handler.getRowsWithColumnsTs(args.tableName, args.rows, args.columns, args.timestamp)
+ rescue Apache::Hadoop::Hbase::Thrift::IOError => io
+ result.io = io
+ end
+ write_result(result, oprot, 'getRowsWithColumnsTs', seqid)
+ end
+
def process_mutateRow(seqid, iprot, oprot)
args = read_args(iprot, MutateRow_args)
result = MutateRow_result.new()
begin
@handler.mutateRow(args.tableName, args.row, args.mutations)
@@ -1574,9 +1682,172 @@
::Thrift::Struct.generate_accessors self
end
class GetRowWithColumnsTs_result
+ include ::Thrift::Struct, ::Thrift::Struct_Union
+ SUCCESS = 0
+ IO = 1
+
+ FIELDS = {
+ SUCCESS => {:type => ::Thrift::Types::LIST, :name => 'success', :element => {:type => ::Thrift::Types::STRUCT, :class => Apache::Hadoop::Hbase::Thrift::TRowResult}},
+ IO => {:type => ::Thrift::Types::STRUCT, :name => 'io', :class => Apache::Hadoop::Hbase::Thrift::IOError}
+ }
+
+ def struct_fields; FIELDS; end
+
+ def validate
+ end
+
+ ::Thrift::Struct.generate_accessors self
+ end
+
+ class GetRows_args
+ include ::Thrift::Struct, ::Thrift::Struct_Union
+ TABLENAME = 1
+ ROWS = 2
+
+ FIELDS = {
+ # name of table
+ TABLENAME => {:type => ::Thrift::Types::STRING, :name => 'tableName', :binary => true},
+ # row keys
+ ROWS => {:type => ::Thrift::Types::LIST, :name => 'rows', :element => {:type => ::Thrift::Types::STRING, :binary => true}}
+ }
+
+ def struct_fields; FIELDS; end
+
+ def validate
+ end
+
+ ::Thrift::Struct.generate_accessors self
+ end
+
+ class GetRows_result
+ include ::Thrift::Struct, ::Thrift::Struct_Union
+ SUCCESS = 0
+ IO = 1
+
+ FIELDS = {
+ SUCCESS => {:type => ::Thrift::Types::LIST, :name => 'success', :element => {:type => ::Thrift::Types::STRUCT, :class => Apache::Hadoop::Hbase::Thrift::TRowResult}},
+ IO => {:type => ::Thrift::Types::STRUCT, :name => 'io', :class => Apache::Hadoop::Hbase::Thrift::IOError}
+ }
+
+ def struct_fields; FIELDS; end
+
+ def validate
+ end
+
+ ::Thrift::Struct.generate_accessors self
+ end
+
+ class GetRowsWithColumns_args
+ include ::Thrift::Struct, ::Thrift::Struct_Union
+ TABLENAME = 1
+ ROWS = 2
+ COLUMNS = 3
+
+ FIELDS = {
+ # name of table
+ TABLENAME => {:type => ::Thrift::Types::STRING, :name => 'tableName', :binary => true},
+ # row keys
+ ROWS => {:type => ::Thrift::Types::LIST, :name => 'rows', :element => {:type => ::Thrift::Types::STRING, :binary => true}},
+ # List of columns to return, null for all columns
+ COLUMNS => {:type => ::Thrift::Types::LIST, :name => 'columns', :element => {:type => ::Thrift::Types::STRING, :binary => true}}
+ }
+
+ def struct_fields; FIELDS; end
+
+ def validate
+ end
+
+ ::Thrift::Struct.generate_accessors self
+ end
+
+ class GetRowsWithColumns_result
+ include ::Thrift::Struct, ::Thrift::Struct_Union
+ SUCCESS = 0
+ IO = 1
+
+ FIELDS = {
+ SUCCESS => {:type => ::Thrift::Types::LIST, :name => 'success', :element => {:type => ::Thrift::Types::STRUCT, :class => Apache::Hadoop::Hbase::Thrift::TRowResult}},
+ IO => {:type => ::Thrift::Types::STRUCT, :name => 'io', :class => Apache::Hadoop::Hbase::Thrift::IOError}
+ }
+
+ def struct_fields; FIELDS; end
+
+ def validate
+ end
+
+ ::Thrift::Struct.generate_accessors self
+ end
+
+ class GetRowsTs_args
+ include ::Thrift::Struct, ::Thrift::Struct_Union
+ TABLENAME = 1
+ ROWS = 2
+ TIMESTAMP = 3
+
+ FIELDS = {
+ # name of the table
+ TABLENAME => {:type => ::Thrift::Types::STRING, :name => 'tableName', :binary => true},
+ # row keys
+ ROWS => {:type => ::Thrift::Types::LIST, :name => 'rows', :element => {:type => ::Thrift::Types::STRING, :binary => true}},
+ # timestamp
+ TIMESTAMP => {:type => ::Thrift::Types::I64, :name => 'timestamp'}
+ }
+
+ def struct_fields; FIELDS; end
+
+ def validate
+ end
+
+ ::Thrift::Struct.generate_accessors self
+ end
+
+ class GetRowsTs_result
+ include ::Thrift::Struct, ::Thrift::Struct_Union
+ SUCCESS = 0
+ IO = 1
+
+ FIELDS = {
+ SUCCESS => {:type => ::Thrift::Types::LIST, :name => 'success', :element => {:type => ::Thrift::Types::STRUCT, :class => Apache::Hadoop::Hbase::Thrift::TRowResult}},
+ IO => {:type => ::Thrift::Types::STRUCT, :name => 'io', :class => Apache::Hadoop::Hbase::Thrift::IOError}
+ }
+
+ def struct_fields; FIELDS; end
+
+ def validate
+ end
+
+ ::Thrift::Struct.generate_accessors self
+ end
+
+ class GetRowsWithColumnsTs_args
+ include ::Thrift::Struct, ::Thrift::Struct_Union
+ TABLENAME = 1
+ ROWS = 2
+ COLUMNS = 3
+ TIMESTAMP = 4
+
+ FIELDS = {
+ # name of table
+ TABLENAME => {:type => ::Thrift::Types::STRING, :name => 'tableName', :binary => true},
+ # row keys
+ ROWS => {:type => ::Thrift::Types::LIST, :name => 'rows', :element => {:type => ::Thrift::Types::STRING, :binary => true}},
+ # List of columns to return, null for all columns
+ COLUMNS => {:type => ::Thrift::Types::LIST, :name => 'columns', :element => {:type => ::Thrift::Types::STRING, :binary => true}},
+ TIMESTAMP => {:type => ::Thrift::Types::I64, :name => 'timestamp'}
+ }
+
+ def struct_fields; FIELDS; end
+
+ def validate
+ end
+
+ ::Thrift::Struct.generate_accessors self
+ end
+
+ class GetRowsWithColumnsTs_result
include ::Thrift::Struct, ::Thrift::Struct_Union
SUCCESS = 0
IO = 1
FIELDS = {