in provider/fastbin/src/main/java/org/apache/aries/rsa/provider/fastbin/tcp/ClientInvokerImpl.java [173:210]
private MethodData getMethodData(Method method) throws IOException {
MethodData rc;
synchronized (method_cache) {
rc = method_cache.get(method);
}
if( rc==null ) {
StringBuilder sb = new StringBuilder();
sb.append(method.getName());
sb.append(",");
Class<?>[] types = method.getParameterTypes();
for(int i = 0; i < types.length; i++) {
if( i != 0 ) {
sb.append(",");
}
sb.append(encodeClassName(types[i]));
}
Buffer signature = new UTF8Buffer(sb.toString()).buffer();
Serialization annotation = method.getAnnotation(Serialization.class);
SerializationStrategy serializationStrategy;
if( annotation!=null ) {
serializationStrategy = serializationStrategies.get(annotation.value());
if( serializationStrategy==null ) {
throw new RuntimeException("Could not find the serialization strategy named: "+annotation.value());
}
} else {
serializationStrategy = ObjectSerializationStrategy.INSTANCE;
}
final InvocationStrategy strategy = InvocationType.forMethod(method);
rc = new MethodData(strategy, serializationStrategy, signature);
synchronized (method_cache) {
method_cache.put(method, rc);
}
}
return rc;
}