Motr  M0
filterc_stub.c
Go to the documentation of this file.
1 /* -*- C -*- */
2 /*
3  * Copyright (c) 2017-2020 Seagate Technology LLC and/or its Affiliates
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  *
17  * For any questions about this software or licensing,
18  * please email opensource@seagate.com or cortx-questions@seagate.com.
19  *
20  */
21 
22 
23 #define M0_TRACE_SUBSYSTEM M0_TRACE_SUBSYS_FDMI
24 #include "lib/trace.h"
25 
26 #include "reqh/reqh.h"
27 #include "fdmi/filterc.h"
28 
29 static int filterc_stub_start(struct m0_filterc_ctx *ctx,
30  struct m0_reqh *reqh);
31 
32 static void filterc_stub_stop(struct m0_filterc_ctx *ctx);
33 
34 static int filterc_stub_open(struct m0_filterc_ctx *ctx,
35  enum m0_fdmi_rec_type_id rec_type_id,
36  struct m0_filterc_iter *iter);
37 
38 static int filterc_stub_get_next(struct m0_filterc_iter *iter,
39  struct m0_conf_fdmi_filter **out);
40 
41 static void filterc_stub_close(struct m0_filterc_iter *iter);
42 
45  .fco_stop = filterc_stub_stop,
46  .fco_open = filterc_stub_open,
47  .fco_get_next = filterc_stub_get_next,
48  .fco_close = filterc_stub_close
49 };
50 
52  struct m0_reqh *reqh)
53 {
54  return 0;
55 }
56 
57 static void filterc_stub_stop(struct m0_filterc_ctx *ctx)
58 {
59 }
60 
62  enum m0_fdmi_rec_type_id rec_type_id,
63  struct m0_filterc_iter *iter)
64 {
65  return 0;
66 }
67 
68 static int filterc_stub_get_next(struct m0_filterc_iter *iter,
69  struct m0_conf_fdmi_filter **out)
70 {
71  *out = NULL;
72  return 0;
73 }
74 
75 static void filterc_stub_close(struct m0_filterc_iter *iter)
76 {
77 }
78 
79 #undef M0_TRACE_SUBSYSTEM
80 
81 /*
82  * Local variables:
83  * c-indentation-style: "K&R"
84  * c-basic-offset: 8
85  * tab-width: 8
86  * fill-column: 80
87  * scroll-step: 1
88  * End:
89  */
90 /*
91  * vim: tabstop=8 shiftwidth=8 noexpandtab textwidth=80 nowrap
92  */
#define NULL
Definition: misc.h:38
static int filterc_stub_start(struct m0_filterc_ctx *ctx, struct m0_reqh *reqh)
Definition: filterc_stub.c:51
static int filterc_stub_open(struct m0_filterc_ctx *ctx, enum m0_fdmi_rec_type_id rec_type_id, struct m0_filterc_iter *iter)
Definition: filterc_stub.c:61
static int filterc_stub_get_next(struct m0_filterc_iter *iter, struct m0_conf_fdmi_filter **out)
Definition: filterc_stub.c:68
Definition: reqh.h:94
m0_fdmi_rec_type_id
Definition: fdmi.h:234
struct m0_reqh reqh
Definition: rm_foms.c:48
const struct m0_filterc_ops filterc_stub_ops
Definition: filterc_stub.c:43
int(* fco_start)(struct m0_filterc_ctx *ctx, struct m0_reqh *reqh)
Definition: filterc.h:56
static void filterc_stub_stop(struct m0_filterc_ctx *ctx)
Definition: filterc_stub.c:57
Definition: nucleus.c:42
#define out(...)
Definition: gen.c:41
static void filterc_stub_close(struct m0_filterc_iter *iter)
Definition: filterc_stub.c:75