private void SetMethodReturnType(ServicePack retPack, MethodInfo method, IDynamicMethodBuilder methodBuilder) { if (!allMethodsVoid) { var matchReturnType = MapType(method.ReturnType, retPack); methodBuilder.SetReturnType(matchReturnType); } }
private void SetMethodParams(ServicePack retPack, MethodInfo method, IDynamicMethodBuilder methodBuilder) { var methodParams = method.GetParameters(); foreach (var param in methodParams) { var matchParamType = MapType(param.ParameterType, retPack); methodBuilder.SetParameter(matchParamType, param.Name); } }