@@ -0,0 +1,1764 @@
+package com.github.ivbaranov.rxbluetooth;%0A%0Aimport android.bluetooth.BluetoothProfile;%0A%0A/**%0A * Event container class.  Contains state (whether the service was just connected or%0A * disconnected), profile type and %7B@link BluetoothProfile%7D. When service state is %7B@link%0A * State#DISCONNECTED%7D the mBluetoothProfile is null.%0A */%0Apublic class ServiceEvent %7B%0A%0A  public enum State %7B%0A    CONNECTED,%0A    DISCONNECTED%0A  %7D%0A%0A  private State mState;%0A  private int mProfileType;%0A  private BluetoothProfile mBluetoothProfile;%0A%0A  public ServiceEvent(State state, int profileType, BluetoothProfile bluetoothProfile) %7B%0A    mState = state;%0A    mProfileType = profileType;%0A    mBluetoothProfile = bluetoothProfile;%0A  %7D%0A%0A  public State getState() %7B%0A    return mState;%0A  %7D%0A%0A  public int getProfileType() %7B%0A    return mProfileType;%0A  %7D%0A%0A  public BluetoothProfile getBluetoothProfile() %7B%0A    return mBluetoothProfile;%0A  %7D%0A%0A  @Override public boolean equals(Object o) %7B%0A    if (this == o) return true;%0A    if (o == null %7C%7C getClass() != o.getClass()) return false;%0A%0A    ServiceEvent that = (ServiceEvent) o;%0A%0A    if (mProfileType != that.mProfileType) return false;%0A    if (mState != that.mState) return false;%0A    return !(mBluetoothProfile != null ? !mBluetoothProfile.equals(that.mBluetoothProfile)%0A        : that.mBluetoothProfile != null);%0A  %7D%0A%0A  @Override public int hashCode() %7B%0A    int result = mState.hashCode();%0A    result = 31 * result + mProfileType;%0A    result = 31 * result + (mBluetoothProfile != null ? mBluetoothProfile.hashCode() : 0);%0A    return result;%0A  %7D%0A%0A  @Override public String toString() %7B%0A    return %22ServiceEvent%7B%22 +%0A        %22mState=%22 + mState +%0A        %22, mProfileType=%22 + mProfileType +%0A        %22, mBluetoothProfile=%22 + mBluetoothProfile +%0A        '%7D';%0A  %7D%0A%7D%0A

Add service event class. It contains state, profile type and profile proxy object.