Reland: Rework platform version to hide codenames.

The public platform version no longer can be a codename, it is
always the most recently released platform.  A new build property
and API provides either the offical version or the current codename
as appropriate.  This will avoid breaking apps that look at the
platform version while development is under a codename.

Bug:  143175463
Change-Id: I8a2c8d37bb61cb7fba34c929b2ada5b33906ceb1
Test: manual
Exempt-From-Owner-Approval: Previously approved, no new changes
diff --git a/dexmaker-mockito-inline-extended/src/main/java/com/android/dx/mockito/inline/InlineStaticMockMaker.java b/dexmaker-mockito-inline-extended/src/main/java/com/android/dx/mockito/inline/InlineStaticMockMaker.java
index f764e07..6ba11cd 100644
--- a/dexmaker-mockito-inline-extended/src/main/java/com/android/dx/mockito/inline/InlineStaticMockMaker.java
+++ b/dexmaker-mockito-inline-extended/src/main/java/com/android/dx/mockito/inline/InlineStaticMockMaker.java
@@ -126,7 +126,8 @@
     public InlineStaticMockMaker() {
         if (INITIALIZATION_ERROR != null) {
             throw new RuntimeException("Could not initialize inline mock maker.\n" + "\n" +
-                    "Release: Android " + Build.VERSION.RELEASE + " " + Build.VERSION.INCREMENTAL
+                    "Release: Android " + Build.VERSION.RELEASE_OR_CODENAME + " "
+                    + Build.VERSION.INCREMENTAL
                     + "Device: " + Build.BRAND + " " + Build.MODEL, INITIALIZATION_ERROR);
         }
 
diff --git a/dexmaker-mockito-inline/src/main/java/com/android/dx/mockito/inline/InlineDexmakerMockMaker.java b/dexmaker-mockito-inline/src/main/java/com/android/dx/mockito/inline/InlineDexmakerMockMaker.java
index 0a594e0..9741118 100644
--- a/dexmaker-mockito-inline/src/main/java/com/android/dx/mockito/inline/InlineDexmakerMockMaker.java
+++ b/dexmaker-mockito-inline/src/main/java/com/android/dx/mockito/inline/InlineDexmakerMockMaker.java
@@ -180,7 +180,8 @@
             throw new RuntimeException(
                     "Could not initialize inline mock maker.\n"
                     + "\n"
-                    + "Release: Android " + Build.VERSION.RELEASE + " " + Build.VERSION.INCREMENTAL
+                    + "Release: Android " + Build.VERSION.RELEASE_OR_CODENAME + " "
+                    + Build.VERSION.INCREMENTAL
                     + "Device: " + Build.BRAND + " " + Build.MODEL, INITIALIZATION_ERROR);
         }