af062818b47340eef15700d2f0211576ba3506eevboxsync/*
af062818b47340eef15700d2f0211576ba3506eevboxsync * Endpoint Mapper
af062818b47340eef15700d2f0211576ba3506eevboxsync *
af062818b47340eef15700d2f0211576ba3506eevboxsync * Copyright 2006 Robert Shearman (for CodeWeavers)
af062818b47340eef15700d2f0211576ba3506eevboxsync *
af062818b47340eef15700d2f0211576ba3506eevboxsync * This library is free software; you can redistribute it and/or
af062818b47340eef15700d2f0211576ba3506eevboxsync * modify it under the terms of the GNU Lesser General Public
af062818b47340eef15700d2f0211576ba3506eevboxsync * License as published by the Free Software Foundation; either
af062818b47340eef15700d2f0211576ba3506eevboxsync * version 2.1 of the License, or (at your option) any later version.
af062818b47340eef15700d2f0211576ba3506eevboxsync *
af062818b47340eef15700d2f0211576ba3506eevboxsync * This library is distributed in the hope that it will be useful,
af062818b47340eef15700d2f0211576ba3506eevboxsync * but WITHOUT ANY WARRANTY; without even the implied warranty of
af062818b47340eef15700d2f0211576ba3506eevboxsync * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
af062818b47340eef15700d2f0211576ba3506eevboxsync * Lesser General Public License for more details.
af062818b47340eef15700d2f0211576ba3506eevboxsync *
af062818b47340eef15700d2f0211576ba3506eevboxsync * You should have received a copy of the GNU Lesser General Public
af062818b47340eef15700d2f0211576ba3506eevboxsync * License along with this library; if not, write to the Free Software
af062818b47340eef15700d2f0211576ba3506eevboxsync * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
af062818b47340eef15700d2f0211576ba3506eevboxsync */
af062818b47340eef15700d2f0211576ba3506eevboxsync
589fd26cedb2b4ebbed14f2964cad03cc8ebbca2vboxsync/*
4b9d6701570cb98fd36e209314239d104ec584d3vboxsync * Oracle LGPL Disclaimer: For the avoidance of doubt, except that if any license choice
4b9d6701570cb98fd36e209314239d104ec584d3vboxsync * other than GPL or LGPL is available it will apply instead, Oracle elects to use only
589fd26cedb2b4ebbed14f2964cad03cc8ebbca2vboxsync * the Lesser General Public License version 2.1 (LGPLv2) at this time for any software where
589fd26cedb2b4ebbed14f2964cad03cc8ebbca2vboxsync * a choice of LGPL license versions is made available with the language indicating
589fd26cedb2b4ebbed14f2964cad03cc8ebbca2vboxsync * that LGPLv2 or any later version may be used, or where a choice of which version
589fd26cedb2b4ebbed14f2964cad03cc8ebbca2vboxsync * of the LGPL is applied is otherwise unspecified.
589fd26cedb2b4ebbed14f2964cad03cc8ebbca2vboxsync */
589fd26cedb2b4ebbed14f2964cad03cc8ebbca2vboxsync
af062818b47340eef15700d2f0211576ba3506eevboxsync/* FIXME: should be import */
af062818b47340eef15700d2f0211576ba3506eevboxsync#include "dcetypes.idl"
af062818b47340eef15700d2f0211576ba3506eevboxsync
af062818b47340eef15700d2f0211576ba3506eevboxsynccpp_quote("RPC_STATUS WINAPI TowerExplode(")
af062818b47340eef15700d2f0211576ba3506eevboxsynccpp_quote(" const twr_t *tower, PRPC_SYNTAX_IDENTIFIER object, PRPC_SYNTAX_IDENTIFIER syntax,")
af062818b47340eef15700d2f0211576ba3506eevboxsynccpp_quote(" char **protseq, char **endpoint, char **address);")
af062818b47340eef15700d2f0211576ba3506eevboxsynccpp_quote("RPC_STATUS WINAPI TowerConstruct(")
af062818b47340eef15700d2f0211576ba3506eevboxsynccpp_quote(" const RPC_SYNTAX_IDENTIFIER *object, const RPC_SYNTAX_IDENTIFIER *syntax,")
af062818b47340eef15700d2f0211576ba3506eevboxsynccpp_quote(" const char *protseq, const char *endpoint, const char *address,")
af062818b47340eef15700d2f0211576ba3506eevboxsynccpp_quote(" twr_t **tower);")
af062818b47340eef15700d2f0211576ba3506eevboxsync
af062818b47340eef15700d2f0211576ba3506eevboxsync[
af062818b47340eef15700d2f0211576ba3506eevboxsync uuid(e1af8308-5d1f-11c9-91a4-08002b14a0fa),
af062818b47340eef15700d2f0211576ba3506eevboxsync version(3.0),
af062818b47340eef15700d2f0211576ba3506eevboxsync pointer_default(ref)
af062818b47340eef15700d2f0211576ba3506eevboxsync]
af062818b47340eef15700d2f0211576ba3506eevboxsyncinterface epm
af062818b47340eef15700d2f0211576ba3506eevboxsync{
af062818b47340eef15700d2f0211576ba3506eevboxsync const long ept_max_annotation_size = 64;
af062818b47340eef15700d2f0211576ba3506eevboxsync
af062818b47340eef15700d2f0211576ba3506eevboxsync typedef struct
af062818b47340eef15700d2f0211576ba3506eevboxsync {
af062818b47340eef15700d2f0211576ba3506eevboxsync GUID object;
af062818b47340eef15700d2f0211576ba3506eevboxsync twr_t *tower;
af062818b47340eef15700d2f0211576ba3506eevboxsync [string] char annotation[ept_max_annotation_size];
af062818b47340eef15700d2f0211576ba3506eevboxsync } ept_entry_t, *ept_entry_p_t;
af062818b47340eef15700d2f0211576ba3506eevboxsync
af062818b47340eef15700d2f0211576ba3506eevboxsync typedef [context_handle] void *ept_lookup_handle_t;
af062818b47340eef15700d2f0211576ba3506eevboxsync
af062818b47340eef15700d2f0211576ba3506eevboxsync /* Adds entries to an endpoint map */
af062818b47340eef15700d2f0211576ba3506eevboxsync void ept_insert(
af062818b47340eef15700d2f0211576ba3506eevboxsync [in] handle_t h,
af062818b47340eef15700d2f0211576ba3506eevboxsync [in] unsigned32 num_ents,
af062818b47340eef15700d2f0211576ba3506eevboxsync [in, size_is(num_ents)]
af062818b47340eef15700d2f0211576ba3506eevboxsync ept_entry_t entries[],
af062818b47340eef15700d2f0211576ba3506eevboxsync [in] boolean32 replace,
af062818b47340eef15700d2f0211576ba3506eevboxsync [out] error_status_t *status
af062818b47340eef15700d2f0211576ba3506eevboxsync );
af062818b47340eef15700d2f0211576ba3506eevboxsync
af062818b47340eef15700d2f0211576ba3506eevboxsync /* Removes entries from an endpoint map */
af062818b47340eef15700d2f0211576ba3506eevboxsync void ept_delete(
af062818b47340eef15700d2f0211576ba3506eevboxsync [in] handle_t h,
af062818b47340eef15700d2f0211576ba3506eevboxsync [in] unsigned32 num_ents,
af062818b47340eef15700d2f0211576ba3506eevboxsync [in, size_is(num_ents)]
af062818b47340eef15700d2f0211576ba3506eevboxsync ept_entry_t entries[],
af062818b47340eef15700d2f0211576ba3506eevboxsync [out] error_status_t *status
af062818b47340eef15700d2f0211576ba3506eevboxsync );
af062818b47340eef15700d2f0211576ba3506eevboxsync
af062818b47340eef15700d2f0211576ba3506eevboxsync /* Lookup entries in an endpoint map */
af062818b47340eef15700d2f0211576ba3506eevboxsync [idempotent]
af062818b47340eef15700d2f0211576ba3506eevboxsync void ept_lookup(
af062818b47340eef15700d2f0211576ba3506eevboxsync [in] handle_t h,
af062818b47340eef15700d2f0211576ba3506eevboxsync [in] unsigned32 inquiry_type,
af062818b47340eef15700d2f0211576ba3506eevboxsync [in] uuid_p_t object,
af062818b47340eef15700d2f0211576ba3506eevboxsync [in] rpc_if_id_p_t interface_id,
af062818b47340eef15700d2f0211576ba3506eevboxsync [in] unsigned32 vers_option,
af062818b47340eef15700d2f0211576ba3506eevboxsync [in, out] ept_lookup_handle_t *entry_handle,
af062818b47340eef15700d2f0211576ba3506eevboxsync [in] unsigned32 max_ents,
af062818b47340eef15700d2f0211576ba3506eevboxsync [out] unsigned32 *num_ents,
af062818b47340eef15700d2f0211576ba3506eevboxsync [out, length_is(*num_ents), size_is(max_ents)]
af062818b47340eef15700d2f0211576ba3506eevboxsync ept_entry_t entries[],
af062818b47340eef15700d2f0211576ba3506eevboxsync [out] error_status_t *status
af062818b47340eef15700d2f0211576ba3506eevboxsync );
af062818b47340eef15700d2f0211576ba3506eevboxsync
af062818b47340eef15700d2f0211576ba3506eevboxsync /* Lookup entries in an endpoint map using the given input pattern */
af062818b47340eef15700d2f0211576ba3506eevboxsync [idempotent]
af062818b47340eef15700d2f0211576ba3506eevboxsync void ept_map(
af062818b47340eef15700d2f0211576ba3506eevboxsync [in] handle_t h,
af062818b47340eef15700d2f0211576ba3506eevboxsync [in] uuid_p_t object,
af062818b47340eef15700d2f0211576ba3506eevboxsync [in] twr_p_t map_tower,
af062818b47340eef15700d2f0211576ba3506eevboxsync [in, out] ept_lookup_handle_t *entry_handle,
af062818b47340eef15700d2f0211576ba3506eevboxsync [in] unsigned32 max_towers,
af062818b47340eef15700d2f0211576ba3506eevboxsync [out] unsigned32 *num_towers,
af062818b47340eef15700d2f0211576ba3506eevboxsync [out, length_is(*num_towers), size_is(max_towers)]
af062818b47340eef15700d2f0211576ba3506eevboxsync twr_p_t *towers,
af062818b47340eef15700d2f0211576ba3506eevboxsync [out] error_status_t *status
af062818b47340eef15700d2f0211576ba3506eevboxsync );
af062818b47340eef15700d2f0211576ba3506eevboxsync
af062818b47340eef15700d2f0211576ba3506eevboxsync /* Free the context handle returned by ept_lookup or ept_map */
af062818b47340eef15700d2f0211576ba3506eevboxsync void ept_lookup_handle_free(
af062818b47340eef15700d2f0211576ba3506eevboxsync [in] handle_t h,
af062818b47340eef15700d2f0211576ba3506eevboxsync [in, out] ept_lookup_handle_t *entry_handle,
af062818b47340eef15700d2f0211576ba3506eevboxsync [out] error_status_t *status
af062818b47340eef15700d2f0211576ba3506eevboxsync );
af062818b47340eef15700d2f0211576ba3506eevboxsync
af062818b47340eef15700d2f0211576ba3506eevboxsync /* Inquires as to the endpoint map's object identifier */
af062818b47340eef15700d2f0211576ba3506eevboxsync [idempotent]
af062818b47340eef15700d2f0211576ba3506eevboxsync void ept_inq_object(
af062818b47340eef15700d2f0211576ba3506eevboxsync [in] handle_t h,
af062818b47340eef15700d2f0211576ba3506eevboxsync [out] GUID *ept_object,
af062818b47340eef15700d2f0211576ba3506eevboxsync [out] error_status_t *status
af062818b47340eef15700d2f0211576ba3506eevboxsync );
af062818b47340eef15700d2f0211576ba3506eevboxsync
af062818b47340eef15700d2f0211576ba3506eevboxsync /* Deletes matching entries in the endpoint map */
af062818b47340eef15700d2f0211576ba3506eevboxsync void ept_mgmt_delete(
af062818b47340eef15700d2f0211576ba3506eevboxsync [in] handle_t h,
af062818b47340eef15700d2f0211576ba3506eevboxsync [in] boolean32 object_speced,
af062818b47340eef15700d2f0211576ba3506eevboxsync [in] uuid_p_t object,
af062818b47340eef15700d2f0211576ba3506eevboxsync [in] twr_p_t tower,
af062818b47340eef15700d2f0211576ba3506eevboxsync [out] error_status_t *status
af062818b47340eef15700d2f0211576ba3506eevboxsync );
af062818b47340eef15700d2f0211576ba3506eevboxsync}