public class RouteUtils
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
RouteUtils.RongActivityType |
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
CONVERSATION_TYPE |
static java.lang.String |
CREATE_CHATROOM |
static java.lang.String |
CUSTOM_SERVICE_INFO |
static java.lang.String |
FORWARD_TYPE |
static java.lang.String |
INDEX_MESSAGE_TIME |
static java.lang.String |
MESSAGE |
static java.lang.String |
MESSAGE_IDS |
static java.lang.String |
TARGET_ID |
static java.lang.String |
TITLE |
Constructor and Description |
---|
RouteUtils() |
Modifier and Type | Method and Description |
---|---|
static java.lang.Class<? extends android.app.Activity> |
getActivity(RouteUtils.RongActivityType type) |
static void |
registerActivity(RouteUtils.RongActivityType activityType,
java.lang.Class<? extends android.app.Activity> activity) |
static void |
routeToCombinePicturePagerActivity(android.content.Context context,
Message message)
启动合并转发消息的图片展示页面
|
static void |
routeToCombineWebViewActivity(android.content.Context context,
int messageId,
java.lang.String uri,
java.lang.String type,
java.lang.String title)
启动合并转发消息的在线展示页面
|
static void |
routeToConversationActivity(android.content.Context context,
Conversation.ConversationType type,
java.lang.String targetId) |
static void |
routeToConversationActivity(android.content.Context context,
Conversation.ConversationType type,
java.lang.String targetId,
android.os.Bundle bundle)
启动会话页面
|
static void |
routeToConversationListActivity(android.content.Context context,
java.lang.String title) |
static void |
routeToFilePreviewActivity(android.content.Context context,
Message message,
FileMessage content,
int progress) |
static void |
routeToForwardSelectConversationActivity(Fragment fragment,
ForwardClickActions.ForwardType type,
java.util.ArrayList<java.lang.Integer> messageIds)
启动转发时选择会话页面
|
static void |
routeToMentionMemberSelectActivity(android.content.Context context,
java.lang.String targetId,
Conversation.ConversationType type)
启动 @ 功能选人页面
|
static void |
routeToSubConversationListActivity(android.content.Context context,
Conversation.ConversationType type,
java.lang.String title)
启动聚合会话页面
|
static void |
routeToWebActivity(android.content.Context context,
java.lang.String url) |
static void |
routeToWebActivity(android.content.Context context,
java.lang.String url,
java.lang.String title)
启动 web view 页面
|
static void |
routeToWebFilePreviewActivity(android.content.Context context,
java.lang.String fileUrl,
java.lang.String fileName,
java.lang.String fileSize)
启动文件在线浏览页面
|
public static final java.lang.String CONVERSATION_TYPE
public static final java.lang.String TARGET_ID
public static final java.lang.String CREATE_CHATROOM
public static final java.lang.String TITLE
public static final java.lang.String INDEX_MESSAGE_TIME
public static final java.lang.String CUSTOM_SERVICE_INFO
public static final java.lang.String FORWARD_TYPE
public static final java.lang.String MESSAGE_IDS
public static final java.lang.String MESSAGE
public static void routeToConversationListActivity(android.content.Context context, java.lang.String title)
public static void routeToConversationActivity(android.content.Context context, Conversation.ConversationType type, java.lang.String targetId)
public static void routeToConversationActivity(android.content.Context context, Conversation.ConversationType type, java.lang.String targetId, android.os.Bundle bundle)
context
- 上下文type
- 会话类型targetId
- 目标 IDbundle
- 启动 activity 时 intent 里需要携带的 bundle 信息。public static void routeToSubConversationListActivity(android.content.Context context, Conversation.ConversationType type, java.lang.String title)
context
- 上下文type
- 聚合会话类型title
- 标题public static void routeToMentionMemberSelectActivity(android.content.Context context, java.lang.String targetId, Conversation.ConversationType type)
context
- 上下文targetId
- 目标 IDtype
- 会话类型public static void routeToWebActivity(android.content.Context context, java.lang.String url)
public static void routeToWebActivity(android.content.Context context, java.lang.String url, java.lang.String title)
context
- 上下文url
- 远端 url 地址title
- 标题public static void routeToFilePreviewActivity(android.content.Context context, Message message, FileMessage content, int progress)
public static void routeToForwardSelectConversationActivity(Fragment fragment, ForwardClickActions.ForwardType type, java.util.ArrayList<java.lang.Integer> messageIds)
fragment
- 当前 fragmenttype
- 转发类型。ForwardClickActions.ForwardType
messageIds
- 转发的消息 id 列表。public static void routeToCombinePicturePagerActivity(android.content.Context context, Message message)
context
- 上下文message
- 合并转发时携带的原始消息public static void routeToCombineWebViewActivity(android.content.Context context, int messageId, java.lang.String uri, java.lang.String type, java.lang.String title)
context
- 上下文messageId
- 消息 iduri
- 远端 url 地址type
- title
- 标题public static void routeToWebFilePreviewActivity(android.content.Context context, java.lang.String fileUrl, java.lang.String fileName, java.lang.String fileSize)
context
- 上下文fileUrl
- 文件远端地址fileName
- 文件名称fileSize
- 文件大小public static void registerActivity(RouteUtils.RongActivityType activityType, java.lang.Class<? extends android.app.Activity> activity)
public static java.lang.Class<? extends android.app.Activity> getActivity(RouteUtils.RongActivityType type)