Package io.rong.imlib.model

## Class ConversationIdentifier

- All Implemented Interfaces:

      public class ConversationIdentifier

  会话标识

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class | Description
    --- | --- | ---

  - ### Field Summary

    Fields
    Modifier and Type | Field | Description
    --- | --- | ---
    `public ConversationType` | `type` |
    `public String` | `targetId` |
    `public String` | `channelId` |
    `public final static Creator<ConversationIdentifier>` | `CREATOR` |

  - ### Constructor Summary

    Constructors
    Constructor | Description
    --- | ---
    `ConversationIdentifier()` |
    `ConversationIdentifier(ConversationType type, String targetId)` |

  - ### Enum Constant Summary

    Enum Constants
    Enum Constant | Description
    --- | ---

  - ### Method Summary

    Modifier and Type | Method | Description
    --- | --- | ---
    `ConversationType` | `getType()` |
    `void` | `setType(ConversationType type)` |
    `String` | `getTargetId()` |
    `void` | `setTargetId(String targetId)` |
    `String` | `getChannelId()` |
    `void` | `setChannelId(String channelId)` |
    `static ConversationIdentifier` | `obtain(ConversationType type, String targetId, String channelId)` |
    `static ConversationIdentifier` | `obtainUltraGroup(String targetId, String channelId)` |
    `static ConversationIdentifier` | `obtainGroup(String targetId)` | 构建GROUP类型ConversationIdentifier，该类型一般不需传channelId
    `static ConversationIdentifier` | `obtainPrivate(String targetId)` | 构建PRIVATE类型ConversationIdentifier，该类型一般不需传channelId
    `static ConversationIdentifier` | `obtainChatroom(String targetId)` | 构建 CHATROOM 类型ConversationIdentifier，该类型一般不需传channelId
    `static ConversationIdentifier` | `obtainCustomer(String targetId)` | 构建 CUSTOMER_SERVICE 类型ConversationIdentifier，该类型一般不需传channelId
    `static ConversationIdentifier` | `obtain(Message message)` |
    `static ConversationIdentifier` | `obtain(Conversation conversation)` |
    `int` | `getTypeValue()` |
    `String` | `optChannelId()` |
    `boolean` | `isValid()` |
    `boolean` | `isValidChannel()` |
    `boolean` | `isChannelIdValid()` |
    `int` | `describeContents()` |
    `void` | `writeToParcel(Parcel dest, int flags)` |
    `boolean` | `equalsWithMessage(Message message)` |
    `String` | `toString()` |

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### ConversationIdentifier

          ConversationIdentifier()

    - #### ConversationIdentifier

          ConversationIdentifier(ConversationType type, String targetId)

  - ### Method Detail

    - #### getType

           ConversationType getType()

    - #### setType

           void setType(ConversationType type)

    - #### getTargetId

           String getTargetId()

    - #### setTargetId

           void setTargetId(String targetId)

    - #### getChannelId

           String getChannelId()

    - #### setChannelId

           void setChannelId(String channelId)

    - #### obtain

           static ConversationIdentifier obtain(ConversationType type, String targetId, String channelId)

    - #### obtainUltraGroup

           static ConversationIdentifier obtainUltraGroup(String targetId, String channelId)

    - #### obtainGroup

           static ConversationIdentifier obtainGroup(String targetId)

      构建GROUP类型ConversationIdentifier，该类型一般不需传channelId

    - #### obtainPrivate

           static ConversationIdentifier obtainPrivate(String targetId)

      构建PRIVATE类型ConversationIdentifier，该类型一般不需传channelId

    - #### obtainChatroom

           static ConversationIdentifier obtainChatroom(String targetId)

      构建 CHATROOM 类型ConversationIdentifier，该类型一般不需传channelId

    - #### obtainCustomer

           static ConversationIdentifier obtainCustomer(String targetId)

      构建 CUSTOMER_SERVICE 类型ConversationIdentifier，该类型一般不需传channelId

    - #### obtain

           static ConversationIdentifier obtain(Message message)

    - #### obtain

           static ConversationIdentifier obtain(Conversation conversation)

    - #### getTypeValue

           int getTypeValue()

    - #### optChannelId

           String optChannelId()

    - #### isValid

           boolean isValid()

    - #### isValidChannel

           boolean isValidChannel()

    - #### isChannelIdValid

           boolean isChannelIdValid()

    - #### describeContents

           int describeContents()

    - #### writeToParcel

           void writeToParcel(Parcel dest, int flags)

    - #### equalsWithMessage

           boolean equalsWithMessage(Message message)

    - #### toString

           String toString()