Update and add imports to stats example in readme.
Update and add imports to stats example in readme.

Changes in this commit:
- Remove use of deprecated AggregationWindow.
- Make methods public to show that they could be called by code that isn't part of the example.
- Rename the class for consistency with the tracing example.
- Run google-java-format.

census-instrumentation/opencensus-java,songy23/instrumentation-java,sebright/opencensus-java,census-instrumentation/opencensus-java,songy23/instrumentation-java,bogdandrutu/instrumentation-java,sebright/instrumentation-java,census-instrumentation/opencensus-java,songy23/instrumentation-java,bogdandrutu/instrumentation-java,bogdandrutu/opencensus-java,bogdandrutu/opencensus-java,sebright/instrumentation-java,sebright/opencensus-java,sebright/opencensus-java,bogdandrutu/opencensus-java