use of com.google.api.codegen.viewmodel.StaticLangApiMethodView in project toolkit by googleapis.
the class CSharpGapicSnippetsTransformer method generateOperationFlattenedAsyncMethod.
private StaticLangApiMethodSnippetView generateOperationFlattenedAsyncMethod(MethodContext methodContext, String suffix) {
SurfaceNamer namer = methodContext.getNamer();
StaticLangApiMethodView method = apiMethodTransformer.generateAsyncOperationFlattenedMethod(methodContext, Collections.<ParamWithSimpleDoc>emptyList(), ClientMethodType.AsyncOperationFlattenedMethod, true);
String callerResponseTypeName = method.operationMethod().clientReturnTypeName();
return StaticLangApiMethodSnippetView.newBuilder().method(method).snippetMethodName(method.name() + suffix).callerResponseTypeName(callerResponseTypeName).apiClassName(namer.getApiWrapperClassName(methodContext.getInterfaceConfig())).apiVariableName(method.apiVariableName()).build();
}
use of com.google.api.codegen.viewmodel.StaticLangApiMethodView in project toolkit by googleapis.
the class CSharpGapicSnippetsTransformer method generatePagedFlattenedMethod.
private StaticLangApiMethodSnippetView generatePagedFlattenedMethod(MethodContext methodContext, String suffix, boolean requiresNamedArguments) {
StaticLangApiMethodView method = apiMethodTransformer.generatePagedFlattenedMethod(methodContext, csharpCommonTransformer.pagedMethodAdditionalParams());
SurfaceNamer namer = methodContext.getNamer();
PageStreamingConfig pageStreaming = methodContext.getMethodConfig().getPageStreaming();
FieldConfig resourceFieldConfig = pageStreaming.getResourcesFieldConfig();
String callerResponseTypeName = namer.getAndSaveCallerPagedResponseTypeName(methodContext, resourceFieldConfig);
return StaticLangApiMethodSnippetView.newBuilder().method(method).snippetMethodName(method.name() + suffix).callerResponseTypeName(callerResponseTypeName).apiClassName(namer.getApiWrapperClassName(methodContext.getInterfaceConfig())).apiVariableName(method.apiVariableName()).requiresNamedArguments(requiresNamedArguments).build();
}
use of com.google.api.codegen.viewmodel.StaticLangApiMethodView in project toolkit by googleapis.
the class CSharpGapicSnippetsTransformer method generateFlattenedAsyncMethod.
private StaticLangApiMethodSnippetView generateFlattenedAsyncMethod(MethodContext methodContext, String suffix) {
StaticLangApiMethodView method = apiMethodTransformer.generateFlattenedAsyncMethod(methodContext, ClientMethodType.FlattenedAsyncCallSettingsMethod);
SurfaceNamer namer = methodContext.getNamer();
String callerResponseTypeName = methodContext.getTypeTable().getAndSaveNicknameFor(namer.getStaticLangCallerAsyncReturnTypeName(methodContext));
return StaticLangApiMethodSnippetView.newBuilder().method(method).snippetMethodName(method.name() + suffix).callerResponseTypeName(callerResponseTypeName).apiClassName(namer.getApiWrapperClassName(methodContext.getInterfaceConfig())).apiVariableName(method.apiVariableName()).build();
}
use of com.google.api.codegen.viewmodel.StaticLangApiMethodView in project toolkit by googleapis.
the class CSharpGapicSnippetsTransformer method generateOperationFlattenedMethod.
private StaticLangApiMethodSnippetView generateOperationFlattenedMethod(MethodContext methodContext, String suffix) {
SurfaceNamer namer = methodContext.getNamer();
StaticLangApiMethodView method = apiMethodTransformer.generateOperationFlattenedMethod(methodContext, Collections.<ParamWithSimpleDoc>emptyList());
String callerResponseTypeName = method.operationMethod().clientReturnTypeName();
return StaticLangApiMethodSnippetView.newBuilder().method(method).snippetMethodName(method.name() + suffix).callerResponseTypeName(callerResponseTypeName).apiClassName(namer.getApiWrapperClassName(methodContext.getInterfaceConfig())).apiVariableName(method.apiVariableName()).build();
}
use of com.google.api.codegen.viewmodel.StaticLangApiMethodView in project toolkit by googleapis.
the class CSharpGapicSnippetsTransformer method generateFlattenedMethod.
private StaticLangApiMethodSnippetView generateFlattenedMethod(MethodContext methodContext, String suffix) {
StaticLangApiMethodView method = apiMethodTransformer.generateFlattenedMethod(methodContext);
SurfaceNamer namer = methodContext.getNamer();
String callerResponseTypeName = methodContext.getTypeTable().getAndSaveNicknameFor(namer.getStaticLangCallerReturnTypeName(methodContext));
return StaticLangApiMethodSnippetView.newBuilder().method(method).snippetMethodName(method.name() + suffix).callerResponseTypeName(callerResponseTypeName).apiClassName(namer.getApiWrapperClassName(methodContext.getInterfaceConfig())).apiVariableName(method.apiVariableName()).build();
}
Aggregations