Microsoft Information Protection SDK - C 1.17
API Reference Documentation for C
Loading...
Searching...
No Matches
task_dispatcher_delegate_cc.h
Go to the documentation of this file.
1/*
2 *
3 * Copyright (c) Microsoft Corporation.
4 * All rights reserved.
5 *
6 * This code is licensed under the MIT License.
7 *
8 * Permission is hereby granted, free of charge, to any person obtaining a copy
9 * of this software and associated documentation files(the "Software"), to deal
10 * in the Software without restriction, including without limitation the rights
11 * to use, copy, modify, merge, publish, distribute, sublicense, and / or sell
12 * copies of the Software, and to permit persons to whom the Software is
13 * furnished to do so, subject to the following conditions :
14 *
15 * The above copyright notice and this permission notice shall be included in
16 * all copies or substantial portions of the Software.
17 *
18 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
19 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
20 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.IN NO EVENT SHALL THE
21 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
22 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
23 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
24 * THE SOFTWARE.
25 *
26 */
27
34#ifndef API_MIP_TASK_DISPATCHER_DELEGATE_CC_H_
35#define API_MIP_TASK_DISPATCHER_DELEGATE_CC_H_
36
37#include <stddef.h>
38#include <stdint.h>
39
41#include "mip_cc/error_cc.h"
43#include "mip_cc/result_cc.h"
44
48typedef struct {
49 const char* id;
50 int64_t delayMs;
54
60MIP_CC_CALLBACK(mip_cc_dispatch_task_callback_fn /*typename*/,
61 void /*return*/,
62 const mip_cc_async_task* /*task*/);
63
71MIP_CC_CALLBACK(mip_cc_cancel_task_callback_fn /*typename*/,
72 bool /*return*/,
73 const char* /*taskId*/);
74
78MIP_CC_CALLBACK(mip_cc_cancel_all_tasks_callback_fn /*typename*/,
79 void /*return*/);
80
82
94MIP_CC_API(mip_cc_result) MIP_CC_CreateTaskDispatcherDelegate(
95 const mip_cc_dispatch_task_callback_fn dispatchTaskCallback,
96 const mip_cc_cancel_task_callback_fn cancelTaskCallback,
97 const mip_cc_cancel_all_tasks_callback_fn cancelAllTasksCallback,
100
111MIP_CC_API(void) MIP_CC_ExecuteDispatchedTask(const mip_cc_task_dispatcher_delegate taskDispatcher, const char* taskId);
112
118MIP_CC_API(void) MIP_CC_ReleaseTaskDispatcherDelegate(mip_cc_task_dispatcher_delegate taskDispatcher);
119
120#endif // API_MIP_TASK_DISPATCHER_DELEGATE_CC_H_
A file Containing the common types used by the upe, file and protection modules.
Error definition and functions.
Export/import and other macros for C API.
Defines success/error result codes.
mip_cc_result
API success/failure result.
Definition result_cc.h:44
Defines a single async task dispatch request.
Definition task_dispatcher_delegate_cc.h:48
void * loggerContext
Definition task_dispatcher_delegate_cc.h:52
bool executeOnIndependentThread
Definition task_dispatcher_delegate_cc.h:51
const char * id
Definition task_dispatcher_delegate_cc.h:49
int64_t delayMs
Definition task_dispatcher_delegate_cc.h:50
Error information.
Definition error_cc.h:79
Opaque handle to MIP object.
Definition common_types_cc.h:44
mip_cc_handle * mip_cc_task_dispatcher_delegate
Definition task_dispatcher_delegate_cc.h:81
const mip_cc_cancel_task_callback_fn const mip_cc_cancel_all_tasks_callback_fn mip_cc_task_dispatcher_delegate mip_cc_error * errorInfo
Definition task_dispatcher_delegate_cc.h:99
const mip_cc_cancel_task_callback_fn const mip_cc_cancel_all_tasks_callback_fn mip_cc_task_dispatcher_delegate * taskDispatcher
Definition task_dispatcher_delegate_cc.h:98
const char * taskId
Definition task_dispatcher_delegate_cc.h:111
MIP_CC_CALLBACK(mip_cc_dispatch_task_callback_fn, void, const mip_cc_async_task *)
Callback function definition for dispatching an async task.
const mip_cc_cancel_task_callback_fn cancelTaskCallback
Definition task_dispatcher_delegate_cc.h:96
MIP_CC_API(void) MIP_CC_ExecuteDispatchedTask(const mip_cc_task_dispatcher_delegate taskDispatcher
Notifies a TaskDispatcher delegate that a task is scheduled to execute now on the current thread.
const mip_cc_cancel_task_callback_fn const mip_cc_cancel_all_tasks_callback_fn cancelAllTasksCallback
Definition task_dispatcher_delegate_cc.h:97