blob: 7101677f3b98660a8f9f7d31cf1146cb6d8121b4 [file] [log] [blame]
Wonsik Kim96a6ae82024-11-08 07:53:33 +00001/*
2 * Copyright (C) 2024 The Android Open Source Project
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17#include <new>
18
19#include <android-base/no_destructor.h>
20#include <apex/ApexCodecs.h>
21
22// TODO: remove when we have real implementations
23#pragma clang diagnostic push
24#pragma clang diagnostic ignored "-Wunused-parameter"
25
26struct ApexCodec_ComponentStore {
27 ApexCodec_ComponentStore() = default;
28};
29
30ApexCodec_ComponentStore *ApexCodec_GetComponentStore() {
31 ::android::base::NoDestructor<ApexCodec_ComponentStore> store;
32 return store.get();
33}
34
35ApexCodec_ComponentTraits *ApexCodec_Traits_get(
36 ApexCodec_ComponentStore *store, size_t index) {
37 return nullptr;
38}
39
40ApexCodec_Status ApexCodec_Component_create(
41 ApexCodec_ComponentStore *store, const char *name, ApexCodec_Component **comp) {
42 *comp = nullptr;
43 return APEXCODEC_STATUS_NOT_FOUND;
44}
45
46void ApexCodec_Component_destroy(ApexCodec_Component *comp) {}
47
48ApexCodec_Status ApexCodec_Component_start(ApexCodec_Component *comp) {
49 return APEXCODEC_STATUS_OMITTED;
50}
51
52ApexCodec_Status ApexCodec_Component_flush(ApexCodec_Component *comp) {
53 return APEXCODEC_STATUS_OMITTED;
54}
55
56ApexCodec_Status ApexCodec_Component_reset(ApexCodec_Component *comp) {
57 return APEXCODEC_STATUS_OMITTED;
58}
59
60ApexCodec_Configurable *ApexCodec_Component_getConfigurable(
61 ApexCodec_Component *comp) {
62 return nullptr;
63}
64
65ApexCodec_Status ApexCodec_SupportedValues_getTypeAndValues(
66 ApexCodec_SupportedValues *supportedValues,
67 ApexCodec_SupportedValuesType *type,
68 ApexCodec_SupportedValuesNumberType *numberType,
69 ApexCodec_Value **values,
70 uint32_t *numValues) {
71 return APEXCODEC_STATUS_OMITTED;
72}
73
74void ApexCodec_SupportedValues_release(ApexCodec_SupportedValues *values) {}
75
76ApexCodec_Status ApexCodec_SettingResults_getResultAtIndex(
77 ApexCodec_SettingResults *results,
78 size_t index,
79 ApexCodec_SettingResultFailure *failure,
80 ApexCodec_ParamFieldValues *field,
81 ApexCodec_ParamFieldValues **conflicts,
82 size_t *numConflicts) {
83 return APEXCODEC_STATUS_OMITTED;
84}
85
86void ApexCodec_SettingResults_release(ApexCodec_SettingResults *results) {}
87
88ApexCodec_Status ApexCodec_Component_process(
89 ApexCodec_Component *comp,
90 const ApexCodec_Buffer *input,
91 ApexCodec_Buffer *output,
92 size_t *consumed,
93 size_t *produced) {
94 return APEXCODEC_STATUS_OMITTED;
95}
96
97ApexCodec_Status ApexCodec_Configurable_config(
98 ApexCodec_Configurable *comp,
99 ApexCodec_LinearBuffer *config,
100 ApexCodec_SettingResults **results) {
101 return APEXCODEC_STATUS_OMITTED;
102}
103
104ApexCodec_Status ApexCodec_Configurable_query(
105 ApexCodec_Configurable *comp,
106 uint32_t indices[],
107 size_t numIndices,
108 ApexCodec_LinearBuffer *config,
109 size_t *written) {
110 return APEXCODEC_STATUS_OMITTED;
111}
112
113ApexCodec_Status ApexCodec_ParamDescriptors_getIndices(
114 ApexCodec_ParamDescriptors *descriptors,
115 uint32_t **indices,
116 size_t *numIndices) {
117 return APEXCODEC_STATUS_OMITTED;
118}
119
120ApexCodec_Status ApexCodec_ParamDescriptors_getDescriptor(
121 ApexCodec_ParamDescriptors *descriptors,
122 uint32_t index,
123 ApexCodec_ParamAttribute *attr,
124 const char **name,
125 uint32_t **dependencies,
126 size_t *numDependencies) {
127 return APEXCODEC_STATUS_OMITTED;
128}
129
130ApexCodec_Status ApexCodec_ParamDescriptors_release(
131 ApexCodec_ParamDescriptors *descriptors) {
132 return APEXCODEC_STATUS_OMITTED;
133}
134
135ApexCodec_Status ApexCodec_Configurable_querySupportedParams(
136 ApexCodec_Configurable *comp,
137 ApexCodec_ParamDescriptors **descriptors) {
138 return APEXCODEC_STATUS_OMITTED;
139}
140
141ApexCodec_Status ApexCodec_Configurable_querySupportedValues(
142 ApexCodec_Configurable *comp,
143 ApexCodec_SupportedValuesQuery *queries,
144 size_t numQueries) {
145 return APEXCODEC_STATUS_OMITTED;
146}
147
148#pragma clang diagnostic pop