Options
All
  • Public
  • Public/Protected
  • All
Menu

Namespace sdkhub

Index

Functions

getAdsPlugin

  • en

    Get Ads Plugin

    zh

    获取广告插件对象类。广告和推送类型只支持单个插件

    example
    var ads = sdkhub.getAdsPlugin();

    Returns ProtocolAds

    if Ads plugin exist, return value Ads User plugin, else return value is null pointer.

getChannelId

  • getChannelId(): string
  • en

    Get channel ID

    zh

    通过插件 ID 获取对应的自定义插件对象类。若只有单个自定义插件,则可不填入 pluginId 参数

    example
    var channelid = sdkhub.getChannelId();

    Returns string

    return value is channel ID.

getCustomPlugin

  • en

    Get Custom Plugin by pluginId

    zh

    通过插件 ID 获取对应的自定义插件对象类。若只有单个自定义插件,则可不填入 pluginId 参数

    example
    var custom = sdkhub.getCustomPlugin();
    var hwcustom = sdkhub.getCustomPlugin("CustomHuawei");

    Parameters

    • Optional pluginId: string

      plugin id

    Returns ProtocolCustom

    if Custom plugin exist, return value is Custom plugin, else return value is null pointer.

getCustomPlugins

  • en

    Get Custom plugins

    zh

    获取所有的自定义插件对象类

    example
    var customs = sdkhub.getCustomPlugins();

    Returns ProtocolCustom[]

    custom plugins

getFeePlugin

  • en

    Get Fee Plugin by pluginId

    zh

    通过插件 ID 获取对应的支付插件对象类。若只有单个支付插件,则可不填入 pluginId 参数

    example
    var fee = sdkhub.getFeePlugin();
    var hwfee = sdkhub.getFeePlugin("FeeHuawei");

    Parameters

    • Optional pluginId: string

      plugin id

    Returns ProtocolFee

    if Fee plugin exist, return value is Fee plugin, else return value is null pointer.

getFeePlugins

  • en

    Get Fee plugins

    zh

    获取所有的支付插件对象类

    example
    var fees = sdkhub.getFeePlugins();

    Returns ProtocolFee[]

    fee plugins

getFrameworkVersion

  • getFrameworkVersion(): string
  • en

    Get framework version

    zh

    获取 Cocos SDKHub 框架版本号

    example
    var version = sdkhub.getFrameworkVersion();

    Returns string

    return value is the version of Cocos SDKHub.

getPluginMethods

  • en

    Get plugin support methods

    zh

    获取插件支持的方法

    example
    var methods = sdkhub.getPluginMethods(sdkhub.getUserPlugin());

    Parameters

    Returns string

    plugin support methods

getPushPlugin

  • en

    Get Push Plugin

    zh

    获取推送插件对象类。广告和推送类型只支持单个插件

    example
    var push = sdkhub.getPushPlugin();

    Returns ProtocolPush

    if Push plugin exist, return value is Push plugin, else return value is null pointer.

getSupportPluginIds

  • getSupportPluginIds(): string
  • en

    Get plugin support ids

    zh

    获取插件列表,可在判断是否含有 UserFeeAdsPushCustom 开头的字段来判断是否存在该类型插件,也可通过其中的插件名,获取指定的插件对象

    example
    var pluginids = sdkhub.getSupportPluginIds();

    Returns string

    plugin support ids

getUserPlugin

  • en

    Get User Plugin by pluginId

    zh

    通过插件 ID 获取对应的用户插件插件对象类。若只有单个用户插件,则可不填入 pluginId 参数

    example
    var user = sdkhub.getUserPlugin();
    var hwuser = sdkhub.getUserPlugin("UserHuawei");

    Parameters

    • Optional pluginId: string

      plugin id

    Returns ProtocolUser

    if User plugin exist, return value is User plugin, else return value is null pointer.

getUserPlugins

  • en

    Get User plugins

    zh

    获取所有的用户插件对象类

    example
    var users = sdkhub.getUserPlugins();

    Returns ProtocolUser[]

    user plugins

Generated using TypeDoc