s3/ldbtools: don't neddlessly link against wbinbind libs
[Samba/gebeck_regimport.git] / source3 / include / wbc_async.h
blobeaec0d11da6d6e1d6c925dcabf241d14b1231d2a
1 /*
2 Unix SMB/CIFS implementation.
3 Headers for the async winbind client library
4 Copyright (C) Kai Blin 2009
6 This program is free software; you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation; either version 3 of the License, or
9 (at your option) any later version.
11 This program is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
16 You should have received a copy of the GNU General Public License
17 along with this program. If not, see <http://www.gnu.org/licenses/>.
20 #ifndef _WBC_ASYNC_H_
21 #define _WBC_ASYNC_H_
23 #include "nsswitch/libwbclient/wbclient.h"
25 struct wb_context;
27 struct tevent_req *wb_trans_send(TALLOC_CTX *mem_ctx,
28 struct tevent_context *ev,
29 struct wb_context *wb_ctx, bool need_priv,
30 struct winbindd_request *wb_req);
31 wbcErr wb_trans_recv(struct tevent_req *req, TALLOC_CTX *mem_ctx,
32 struct winbindd_response **presponse);
33 struct wb_context *wb_context_init(TALLOC_CTX *mem_ctx);
35 /* Definitions from wb_reqtrans.c */
36 wbcErr map_wbc_err_from_errno(int error);
38 bool tevent_req_is_wbcerr(struct tevent_req *req, wbcErr *pwbc_err);
39 wbcErr tevent_req_simple_recv_wbcerr(struct tevent_req *req);
41 struct tevent_req *wb_req_read_send(TALLOC_CTX *mem_ctx,
42 struct tevent_context *ev,
43 int fd, size_t max_extra_data);
44 wbcErr wb_req_read_recv(struct tevent_req *req, TALLOC_CTX *mem_ctx,
45 struct winbindd_request **preq);
47 struct tevent_req *wb_req_write_send(TALLOC_CTX *mem_ctx,
48 struct tevent_context *ev,
49 struct tevent_queue *queue, int fd,
50 struct winbindd_request *wb_req);
51 wbcErr wb_req_write_recv(struct tevent_req *req);
53 struct tevent_req *wb_resp_read_send(TALLOC_CTX *mem_ctx,
54 struct tevent_context *ev, int fd);
55 wbcErr wb_resp_read_recv(struct tevent_req *req, TALLOC_CTX *mem_ctx,
56 struct winbindd_response **presp);
58 struct tevent_req *wb_resp_write_send(TALLOC_CTX *mem_ctx,
59 struct tevent_context *ev,
60 struct tevent_queue *queue, int fd,
61 struct winbindd_response *wb_resp);
62 wbcErr wb_resp_write_recv(struct tevent_req *req);
64 #endif /*_WBC_ASYNC_H_*/