Skip to content

SUDRTGameCoreManager ​

以下为完整接口声明,包含参数键及回调。 通过 getManager 获取实例。

global.sud.op.runtime.core.SUDRTGameCoreManager

方法说明 ​

方法说明
getCoreInfo(version)查询指定 Core 版本的信息,返回 Bundle。
installCore(options, listener)安装 Core;options 使用下列 KEY_CORE_* 常量。通过安装回调接收开始、进度及成功/失败。
listCore(listener)通过 onListSuccess(Bundle[]) 获取 Core 列表。
removeCore(version, listener)删除指定 Core 版本,通过监听器接收结果。
cancelCoreRequest()取消 Core 管理请求;不要将取消调用视为安装成功。

声明、参数键及回调 ​

java
public interface SUDRTGameCoreManager {
    String KEY_CORE_HASH = "rt_core_hash";
    String KEY_CORE_PATH = "rt_core_path";
    String KEY_CORE_REINSTALL = "rt_core_reinstall";
    String KEY_CORE_DELETE_INSTALLATION_PACKAGE = "rt_core_delete_installation_package";
    String KEY_CORE_VERSION = "rt_core_version";
    String KEY_CORE_VERSION_DESC = "rt_core_version_desc";

    void cancelCoreRequest();

    Bundle getCoreInfo(String version);

    void installCore(@NonNull Bundle options, @NonNull CoreInstallListener var2);

    void listCore(@NonNull CoreListListener var1);

    void removeCore(@NonNull String version, @NonNull CoreRemoveListener var2);

    public interface CoreInstallListener {
        void onInstallStart();

        void onInstallProgress(float var1);

        void onInstallSuccess();

        void onInstallFailure(Throwable var1);
    }

    public interface CoreListListener {
        void onListSuccess(Bundle[] var1);

        void onListFailure(Throwable var1);
    }

    public interface CoreRemoveListener {
        void onRemoveSuccess();

        void onRemoveFailure(Throwable var1);
    }
}