blob: 088418e82018d3c64d92bf2d48f8bd77d6b93686 [file] [log] [blame]
package com.google.net.stubby.stub;
import com.google.net.stubby.Channel;
import com.google.net.stubby.MethodDescriptor;
import com.google.net.stubby.Session;
/**
* This class is a shim between Session & Channel. Will be removed when the new transport
* API is introduced.
*/
public class SessionChannel implements Channel {
private final Session session;
public SessionChannel(Session session) {
this.session = session;
}
@Override
public <ReqT, RespT> SessionCall<ReqT, RespT> newCall(MethodDescriptor<ReqT, RespT> method) {
return new SessionCall<ReqT, RespT>(method, session);
}
}