Subversion Repositories SmartDukaan

Rev

Rev 3339 | Rev 3390 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 3339 Rev 3374
Line 23... Line 23...
23
import org.apache.thrift.meta_data.*;
23
import org.apache.thrift.meta_data.*;
24
import org.apache.thrift.protocol.*;
24
import org.apache.thrift.protocol.*;
25
 
25
 
26
public class CRMService {
26
public class CRMService {
27
 
27
 
28
  public interface Iface {
28
  public interface Iface extends in.shop2020.generic.GenericService.Iface {
29
 
29
 
30
    public List<Ticket> getTickets(long customerId) throws TException;
30
    public List<Ticket> getTickets(long customerId) throws TException;
31
 
31
 
32
    public List<Ticket> getAssignedTickets(long agentId) throws TException;
32
    public List<Ticket> getAssignedTickets(long agentId) throws TException;
33
 
33
 
Line 69... Line 69...
69
 
69
 
70
    public void updateLastEmailProcessedTimestamp(long timestamp) throws TException;
70
    public void updateLastEmailProcessedTimestamp(long timestamp) throws TException;
71
 
71
 
72
  }
72
  }
73
 
73
 
74
  public static class Client implements Iface {
74
  public static class Client extends in.shop2020.generic.GenericService.Client implements Iface {
75
    public Client(TProtocol prot)
75
    public Client(TProtocol prot)
76
    {
76
    {
77
      this(prot, prot);
77
      this(prot, prot);
78
    }
78
    }
79
 
79
 
80
    public Client(TProtocol iprot, TProtocol oprot)
80
    public Client(TProtocol iprot, TProtocol oprot)
81
    {
81
    {
82
      iprot_ = iprot;
-
 
83
      oprot_ = oprot;
82
      super(iprot, oprot);
84
    }
-
 
85
 
-
 
86
    protected TProtocol iprot_;
-
 
87
    protected TProtocol oprot_;
-
 
88
 
-
 
89
    protected int seqid_;
-
 
90
 
-
 
91
    public TProtocol getInputProtocol()
-
 
92
    {
-
 
93
      return this.iprot_;
-
 
94
    }
-
 
95
 
-
 
96
    public TProtocol getOutputProtocol()
-
 
97
    {
-
 
98
      return this.oprot_;
-
 
99
    }
83
    }
100
 
84
 
101
    public List<Ticket> getTickets(long customerId) throws TException
85
    public List<Ticket> getTickets(long customerId) throws TException
102
    {
86
    {
103
      send_getTickets(customerId);
87
      send_getTickets(customerId);
Line 778... Line 762...
778
      iprot_.readMessageEnd();
762
      iprot_.readMessageEnd();
779
      return;
763
      return;
780
    }
764
    }
781
 
765
 
782
  }
766
  }
783
  public static class Processor implements TProcessor {
767
  public static class Processor extends in.shop2020.generic.GenericService.Processor implements TProcessor {
784
    private static final Logger LOGGER = LoggerFactory.getLogger(Processor.class.getName());
768
    private static final Logger LOGGER = LoggerFactory.getLogger(Processor.class.getName());
785
    public Processor(Iface iface)
769
    public Processor(Iface iface)
786
    {
770
    {
-
 
771
      super(iface);
787
      iface_ = iface;
772
      iface_ = iface;
788
      processMap_.put("getTickets", new getTickets());
773
      processMap_.put("getTickets", new getTickets());
789
      processMap_.put("getAssignedTickets", new getAssignedTickets());
774
      processMap_.put("getAssignedTickets", new getAssignedTickets());
790
      processMap_.put("getUnassignedTickets", new getUnassignedTickets());
775
      processMap_.put("getUnassignedTickets", new getUnassignedTickets());
791
      processMap_.put("getAllTickets", new getAllTickets());
776
      processMap_.put("getAllTickets", new getAllTickets());
Line 806... Line 791...
806
      processMap_.put("getPermissionsForRoleName", new getPermissionsForRoleName());
791
      processMap_.put("getPermissionsForRoleName", new getPermissionsForRoleName());
807
      processMap_.put("getLastEmailProcessedTimestamp", new getLastEmailProcessedTimestamp());
792
      processMap_.put("getLastEmailProcessedTimestamp", new getLastEmailProcessedTimestamp());
808
      processMap_.put("updateLastEmailProcessedTimestamp", new updateLastEmailProcessedTimestamp());
793
      processMap_.put("updateLastEmailProcessedTimestamp", new updateLastEmailProcessedTimestamp());
809
    }
794
    }
810
 
795
 
811
    protected static interface ProcessFunction {
-
 
812
      public void process(int seqid, TProtocol iprot, TProtocol oprot) throws TException;
-
 
813
    }
-
 
814
 
-
 
815
    private Iface iface_;
796
    private Iface iface_;
816
    protected final HashMap<String,ProcessFunction> processMap_ = new HashMap<String,ProcessFunction>();
-
 
817
 
797
 
818
    public boolean process(TProtocol iprot, TProtocol oprot) throws TException
798
    public boolean process(TProtocol iprot, TProtocol oprot) throws TException
819
    {
799
    {
820
      TMessage msg = iprot.readMessageBegin();
800
      TMessage msg = iprot.readMessageBegin();
821
      ProcessFunction fn = processMap_.get(msg.name);
801
      ProcessFunction fn = processMap_.get(msg.name);