private static void UpdateDndConfigCompleted(int rescode, string content, string json_params, IntPtr user_data) { DndConfigParam param = DndConfigParam.Deserialize(content); user_data.InvokeOnce <DndConfigureDelegate>((ResponseCode)rescode, param); }
/// <summary> /// ios 免打扰设置 /// </summary> /// <param name="param"></param> /// <param name="cb"></param> public static void SetDndConfig(DndConfigParam param, DndConfigureDelegate cb) { var ptr = DelegateConverter.ConvertToIntPtr(cb); ClientNativeMethods.nim_client_set_dnd_config(param.Serialize(), null, UpdateDndConfigCb, ptr); }