You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by pm...@apache.org on 2009/03/24 23:09:22 UTC
svn commit: r758048 -
/incubator/cassandra/trunk/src/org/apache/cassandra/service/Cassandra.java
Author: pmalik
Date: Tue Mar 24 22:09:21 2009
New Revision: 758048
URL: http://svn.apache.org/viewvc?rev=758048&view=rev
Log:
new thrift file changes
Modified:
incubator/cassandra/trunk/src/org/apache/cassandra/service/Cassandra.java
Modified: incubator/cassandra/trunk/src/org/apache/cassandra/service/Cassandra.java
URL: http://svn.apache.org/viewvc/incubator/cassandra/trunk/src/org/apache/cassandra/service/Cassandra.java?rev=758048&r1=758047&r2=758048&view=diff
==============================================================================
--- incubator/cassandra/trunk/src/org/apache/cassandra/service/Cassandra.java (original)
+++ incubator/cassandra/trunk/src/org/apache/cassandra/service/Cassandra.java Tue Mar 24 22:09:21 2009
@@ -18,7 +18,7 @@
public class Cassandra {
- public interface Iface extends com.facebook.fb303.FacebookService.Iface {
+ public interface Iface {
public List<column_t> get_slice(String tablename, String key, String columnFamily_column, int start, int count) throws CassandraException, TException;
@@ -60,7 +60,7 @@
}
- public static class Client extends com.facebook.fb303.FacebookService.Client implements Iface {
+ public static class Client implements Iface {
public Client(TProtocol prot)
{
this(prot, prot);
@@ -68,7 +68,23 @@
public Client(TProtocol iprot, TProtocol oprot)
{
- super(iprot, oprot);
+ iprot_ = iprot;
+ oprot_ = oprot;
+ }
+
+ protected TProtocol iprot_;
+ protected TProtocol oprot_;
+
+ protected int seqid_;
+
+ public TProtocol getInputProtocol()
+ {
+ return this.iprot_;
+ }
+
+ public TProtocol getOutputProtocol()
+ {
+ return this.oprot_;
}
public List<column_t> get_slice(String tablename, String key, String columnFamily_column, int start, int count) throws CassandraException, TException
@@ -669,10 +685,9 @@
}
}
- public static class Processor extends com.facebook.fb303.FacebookService.Processor implements TProcessor {
+ public static class Processor implements TProcessor {
public Processor(Iface iface)
{
- super(iface);
iface_ = iface;
processMap_.put("get_slice", new get_slice());
processMap_.put("get_slice_by_names", new get_slice_by_names());
@@ -695,7 +710,12 @@
processMap_.put("executeQuery", new executeQuery());
}
+ protected static interface ProcessFunction {
+ public void process(int seqid, TProtocol iprot, TProtocol oprot) throws TException;
+ }
+
private Iface iface_;
+ protected final HashMap<String,ProcessFunction> processMap_ = new HashMap<String,ProcessFunction>();
public boolean process(TProtocol iprot, TProtocol oprot) throws TException
{