Debian Codegraph @

runtime/sigprov.h

raw
1 /* The interface definition for (file) signature providers.
2 *
3 * This is just an abstract driver interface, which needs to be
4 * implemented by concrete classes.
5 *
6 * Copyright 2013 Adiscon GmbH.
7 *
8 * This file is part of the rsyslog runtime library.
9 *
10 * Licensed under the Apache License, Version 2.0 (the "License");
11 * you may not use this file except in compliance with the License.
12 * You may obtain a copy of the License at
13 *
14 * http://www.apache.org/licenses/LICENSE-2.0
15 * -or-
16 * see COPYING.ASL20 in the source distribution
17 *
18 * Unless required by applicable law or agreed to in writing, software
19 * distributed under the License is distributed on an "AS IS" BASIS,
20 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
21 * See the License for the specific language governing permissions and
22 * limitations under the License.
23 */
24 #ifndef INCLUDED_SIGPROV_H
25 #define INCLUDED_SIGPROV_H
26
27 /* interface */
28 BEGINinterface(sigprov) /* name must also be changed in ENDinterface macro! */
29 rsRetVal (*Construct)(void *ppThis);
30 rsRetVal (*SetCnfParam)(void *ppThis, struct nvlst *lst);
31 rsRetVal (*Destruct)(void *ppThis);
32 rsRetVal (*OnFileOpen)(void *pThis, uchar *fn, void *pFileInstData);
33 rsRetVal (*OnRecordWrite)(void *pFileInstData, uchar *rec, rs_size_t lenRec);
34 rsRetVal (*OnFileClose)(void *pFileInstData);
35 ENDinterface(sigprov)
36 #define sigprovCURR_IF_VERSION 1 /* increment whenever you change the interface structure! */
37 #endif /* #ifndef INCLUDED_SIGPROV_H */