THRIFT-746. java: Generated services Iface/Client inner classes do not derive from...
authorBryan Duxbury <bryanduxbury@apache.org>
Sat, 3 Apr 2010 23:19:52 +0000 (23:19 +0000)
committerBryan Duxbury <bryanduxbury@apache.org>
Sat, 3 Apr 2010 23:19:52 +0000 (23:19 +0000)
commitb1f7f7973bed233ec6f21807dfd774f7b600c5ec
tree2e3468f58310b9bb534a51ff7abc461a6e493408
parent88569a25d1e8380574de16be541f9e6e18bbca12
THRIFT-746. java: Generated services Iface/Client inner classes do not derive from base classes

This patch causes all generated Client classes to inherit from TServiceClient, an interface that provides a way to get the protocols the Client is using. Also, it causes a new TServiceClientFactory implementation to generated for each Service, which provides a generic, reflection-free way to get Clients. These changes make it easier to build generic pools of Client objects.

Patch: Mathias Herberts

git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@930601 13f79535-47bb-0310-9956-ffa450edef68
compiler/cpp/src/generate/t_java_generator.cc
lib/java/src/org/apache/thrift/TServiceClient.java [new file with mode: 0644]
lib/java/src/org/apache/thrift/TServiceClientFactory.java [new file with mode: 0644]