diff options
author | Tej Singh <singhtejinder@google.com> | 2019-03-23 17:26:32 -0700 |
---|---|---|
committer | Tej Singh <singhtejinder@google.com> | 2019-04-06 01:26:12 +0000 |
commit | 2910d5aa16fbde8e6cc26975e8ef070e9e5c4d36 (patch) | |
tree | 1e5f8ec7f8504e01648168fa56f2fc4c7012a2af /tools/stats_log_api_gen/Collation.cpp | |
parent | 67a43354b375693a56ff207e3b57b4249202ff55 (diff) |
Java code for mainline modules to log to statsd.
Adds support for generating app code to allow java mainline modules to
call the StatsLog.writeRaw public API. Supports primitives, enums,
attribution chains, MODE_BYTES. Does not support key value pairs,
worksource methods (because worksource uses hidden apis in the
worksource object).
Test: manually tested atom logging from DocumentsUI
Test: existing autogenerated code is not modified
Test: cts will follow
Bug: 126134616
Change-Id: Ia321cf2d9952e3875ed0c7a28db1f4113711513f
Diffstat (limited to 'tools/stats_log_api_gen/Collation.cpp')
-rw-r--r-- | tools/stats_log_api_gen/Collation.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/tools/stats_log_api_gen/Collation.cpp b/tools/stats_log_api_gen/Collation.cpp index e66ead7ec340..373adca994a1 100644 --- a/tools/stats_log_api_gen/Collation.cpp +++ b/tools/stats_log_api_gen/Collation.cpp @@ -226,6 +226,14 @@ int collate_atom(const Descriptor *atom, AtomDecl *atomDecl, errorCount++; continue; } + + // Doubles are not supported yet. + if (javaType == JAVA_TYPE_DOUBLE) { + print_error(field, "Doubles are not supported in atoms. Please change field %s to float\n", + field->name().c_str()); + errorCount++; + continue; + } } // Check that if there's an attribution chain, it's at position 1. |