3838import java .util .concurrent .TimeoutException ;
3939
4040/**
41- * Base class for {@link ApiService}. Similar to Guava's {@code AbstractService} but redeclared to
41+ * Base class for {@link ApiService}. Similar to Guava's {@code AbstractService} but redeclared so
4242 * that Guava can be shaded.
4343 */
4444public abstract class AbstractApiService implements ApiService {
45- private static final ImmutableMap <Service .State , ApiService .State > guavaToGaxState =
45+ private static final ImmutableMap <Service .State , ApiService .State > GUAVA_TO_API_SERVICE_STATE =
4646 ImmutableMap .<Service .State , ApiService .State >builder ()
4747 .put (Service .State .FAILED , ApiService .State .FAILED )
4848 .put (Service .State .NEW , ApiService .State .NEW )
@@ -66,7 +66,7 @@ public void addListener(final ApiService.Listener listener, Executor executor) {
6666 new Service .Listener () {
6767 @ Override
6868 public void failed (Service .State from , Throwable failure ) {
69- listener .failed (guavaToGaxState .get (from ), failure );
69+ listener .failed (GUAVA_TO_API_SERVICE_STATE .get (from ), failure );
7070 }
7171
7272 @ Override
@@ -81,12 +81,12 @@ public void starting() {
8181
8282 @ Override
8383 public void stopping (Service .State from ) {
84- listener .stopping (guavaToGaxState .get (from ));
84+ listener .stopping (GUAVA_TO_API_SERVICE_STATE .get (from ));
8585 }
8686
8787 @ Override
8888 public void terminated (Service .State from ) {
89- listener .terminated (guavaToGaxState .get (from ));
89+ listener .terminated (GUAVA_TO_API_SERVICE_STATE .get (from ));
9090 }
9191 },
9292 executor );
@@ -122,7 +122,7 @@ public ApiService startAsync() {
122122 }
123123
124124 public State state () {
125- return guavaToGaxState .get (impl .state ());
125+ return GUAVA_TO_API_SERVICE_STATE .get (impl .state ());
126126 }
127127
128128 public ApiService stopAsync () {
0 commit comments