API Cleanup - rename IConferenceable to Conferenceable.

Bug: 20165255
Change-Id: If4cb323749b6ef9e8657506434d760d07c34167f
diff --git a/telecomm/java/android/telecom/Conference.java b/telecomm/java/android/telecom/Conference.java
index 15a1da1..bab60fe 100644
--- a/telecomm/java/android/telecom/Conference.java
+++ b/telecomm/java/android/telecom/Conference.java
@@ -29,7 +29,7 @@
 /**
  * Represents a conference call which can contain any number of {@link Connection} objects.
  */
-public abstract class Conference implements IConferenceable {
+public abstract class Conference implements Conferenceable {
 
     /**
      * Used to indicate that the conference connection time is not specified.  If not specified,
diff --git a/telecomm/java/android/telecom/Conferenceable.java b/telecomm/java/android/telecom/Conferenceable.java
new file mode 100644
index 0000000..5c4cbc5
--- /dev/null
+++ b/telecomm/java/android/telecom/Conferenceable.java
@@ -0,0 +1,26 @@
+/*
+ * Copyright (C) 2015 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License
+ */
+
+package android.telecom;
+
+/**
+ * Interface used to identify entities with which another entity can participate in a conference
+ * call with.  The {@link ConnectionService} implementation will only recognize
+ * {@link Conferenceable}s which are {@link Connection}s or {@link Conference}s.
+ */
+public interface Conferenceable {
+
+}
diff --git a/telecomm/java/android/telecom/Connection.java b/telecomm/java/android/telecom/Connection.java
index 4762031..f7c69cf 100644
--- a/telecomm/java/android/telecom/Connection.java
+++ b/telecomm/java/android/telecom/Connection.java
@@ -44,7 +44,7 @@
  * must call {@link #destroy()} to signal to the framework that the {@code Connection} is no
  * longer used and associated resources may be recovered.
  */
-public abstract class Connection implements IConferenceable {
+public abstract class Connection implements Conferenceable {
 
     public static final int STATE_INITIALIZING = 0;
 
@@ -374,7 +374,7 @@
         public void onAudioModeIsVoipChanged(Connection c, boolean isVoip) {}
         public void onStatusHintsChanged(Connection c, StatusHints statusHints) {}
         public void onConferenceablesChanged(
-                Connection c, List<IConferenceable> conferenceables) {}
+                Connection c, List<Conferenceable> conferenceables) {}
         public void onConferenceChanged(Connection c, Conference conference) {}
         /** @hide */
         public void onConferenceParticipantsChanged(Connection c,
@@ -788,8 +788,8 @@
      */
     private final Set<Listener> mListeners = Collections.newSetFromMap(
             new ConcurrentHashMap<Listener, Boolean>(8, 0.9f, 1));
-    private final List<IConferenceable> mConferenceables = new ArrayList<>();
-    private final List<IConferenceable> mUnmodifiableConferenceables =
+    private final List<Conferenceable> mConferenceables = new ArrayList<>();
+    private final List<Conferenceable> mUnmodifiableConferenceables =
             Collections.unmodifiableList(mConferenceables);
 
     private int mState = STATE_NEW;
@@ -1277,9 +1277,9 @@
      *
      * @param conferenceables The conferenceables.
      */
-    public final void setConferenceables(List<IConferenceable> conferenceables) {
+    public final void setConferenceables(List<Conferenceable> conferenceables) {
         clearConferenceableList();
-        for (IConferenceable c : conferenceables) {
+        for (Conferenceable c : conferenceables) {
             // If statement checks for duplicates in input. It makes it N^2 but we're dealing with a
             // small amount of items here.
             if (!mConferenceables.contains(c)) {
@@ -1299,7 +1299,7 @@
     /**
      * Returns the connections or conferences with which this connection can be conferenced.
      */
-    public final List<IConferenceable> getConferenceables() {
+    public final List<Conferenceable> getConferenceables() {
         return mUnmodifiableConferenceables;
     }
 
@@ -1564,7 +1564,7 @@
     }
 
     private final void clearConferenceableList() {
-        for (IConferenceable c : mConferenceables) {
+        for (Conferenceable c : mConferenceables) {
             if (c instanceof Connection) {
                 Connection connection = (Connection) c;
                 connection.removeConnectionListener(mConnectionDeathListener);
diff --git a/telecomm/java/android/telecom/ConnectionService.java b/telecomm/java/android/telecom/ConnectionService.java
index e36d32b..89c5667 100644
--- a/telecomm/java/android/telecom/ConnectionService.java
+++ b/telecomm/java/android/telecom/ConnectionService.java
@@ -539,7 +539,7 @@
 
         @Override
         public void onConferenceablesChanged(
-                Connection connection, List<IConferenceable> conferenceables) {
+                Connection connection, List<Conferenceable> conferenceables) {
             mAdapter.setConferenceableConnections(
                     mIdByConnection.get(connection),
                     createIdList(conferenceables));
@@ -1176,14 +1176,14 @@
 
     /**
      * Builds a list of {@link Connection} and {@link Conference} IDs based on the list of
-     * {@link IConferenceable}s passed in.
+     * {@link Conferenceable}s passed in.
      *
-     * @param conferenceables The {@link IConferenceable} connections and conferences.
+     * @param conferenceables The {@link Conferenceable} connections and conferences.
      * @return List of string conference and call Ids.
      */
-    private List<String> createIdList(List<IConferenceable> conferenceables) {
+    private List<String> createIdList(List<Conferenceable> conferenceables) {
         List<String> ids = new ArrayList<>();
-        for (IConferenceable c : conferenceables) {
+        for (Conferenceable c : conferenceables) {
             // Only allow Connection and Conference conferenceables.
             if (c instanceof Connection) {
                 Connection connection = (Connection) c;
diff --git a/telecomm/java/android/telecom/IConferenceable.java b/telecomm/java/android/telecom/IConferenceable.java
index a9be20b..a664baa 100644
--- a/telecomm/java/android/telecom/IConferenceable.java
+++ b/telecomm/java/android/telecom/IConferenceable.java
@@ -19,8 +19,10 @@
 /**
  * Interface used to identify entities with which another entity can participate in a conference
  * call with.  The {@link ConnectionService} implementation will only recognize
- * {@link IConferenceable}s which are {@link Connection}s or {@link Conference}s.
+ * {@link Conferenceable}s which are {@link Connection}s or {@link Conference}s.
+ * <p>
+ * @deprecated use {@link Conferenceable} instead.
+ * @hide
  */
-public interface IConferenceable {
-
+public interface IConferenceable extends Conferenceable {
 }