public class GeneratedCatalogCodeGenerator extends Object implements Generator
Example generated code snippets:
public GoogleAdsVersion getVersion1() {
return new V1Client(provider, credentials);
}
...
private static class V1Client implements GoogleAdsVersion {
...
public UserListServiceClient createUserListServiceClient() {
...
}
...
}
| Constructor and Description |
|---|
GeneratedCatalogCodeGenerator(Set<Integer> versions,
int latestVersion,
String catalogName,
Elements elementUtils,
Messager messager,
Filer filer)
Creates and instance of the generator.
|
| Modifier and Type | Method and Description |
|---|---|
void |
generate()
Generates the code for the GeneratedCatalog class and writes the file.
|
public GeneratedCatalogCodeGenerator(Set<Integer> versions, int latestVersion, String catalogName, Elements elementUtils, Messager messager, Filer filer)
versions - available versions of the Google Ads library.latestVersion - the latest available version of the Google Ads library.catalogName - the catalogName parameter found in the VersionDescriptor annotation that
will be used to namespace the output classname (can be an empty string).messager - the processing environment's messager.filer - the processing environment's filer.Copyright © 2020. All rights reserved.