L4Re Operating System Framework
Interface and Usage Documentation
Loading...
Searching...
No Matches
L4::Ipc::Msg::Svr_val_ops< MTYPE, DIR, CLASS > Struct Template Reference

Defines client-side handling of `MTYPE' as RPC argument. More...

Inheritance diagram for L4::Ipc::Msg::Svr_val_ops< MTYPE, DIR, CLASS >:
Collaboration diagram for L4::Ipc::Msg::Svr_val_ops< MTYPE, DIR, CLASS >:

Detailed Description

template<typename MTYPE, typename DIR, typename CLASS>
struct L4::Ipc::Msg::Svr_val_ops< MTYPE, DIR, CLASS >

Defines client-side handling of `MTYPE' as RPC argument.

Template Parameters
MTYPEElem<T>::arg_type (where T is the type used in the RPC definition)
DIRDir_in (client -> server), or Dir_out (server -> client)
CLASSCls_data, Cls_item, or Cls_buffer */ template<typename MTYPE, typename DIR, typename CLASS> struct Clnt_val_ops;

template<typename T> struct Clnt_noops { template<typename A, typename B> static constexpr int to_msg(char *, unsigned offset, unsigned, T, A, B) noexcept { return offset; }

/ copy data from the message to the client reference template<typename A, typename B> static constexpr int from_msg(char *, unsigned offset, unsigned, long, T const &, A, B) noexcept { return offset; } };

template<typename T> struct Svr_noops { template<typename A, typename B> static constexpr int from_svr(char *, unsigned offset, unsigned, long, T, A, B) noexcept { return offset; }

/ copy data from the message to the client reference template<typename A, typename B> static constexpr int to_svr(char *, unsigned offset, unsigned, T, A, B) noexcept { return offset; } };

template<typename MTYPE, typename CLASS> struct Clnt_val_ops<MTYPE, Dir_in, CLASS> : Clnt_noops<MTYPE> { using Clnt_noops<MTYPE>::to_msg; / Copy a T into the message static int to_msg(char *msg, unsigned offset, unsigned limit, MTYPE arg, Dir_in, CLASS) noexcept { return msg_add<MTYPE>(msg, offset, limit, arg); } };

template<typename MTYPE, typename CLASS> struct Clnt_val_ops<MTYPE, Dir_out, CLASS> : Clnt_noops<MTYPE> { using Clnt_noops<MTYPE>::from_msg; / copy data from the message to the client reference static int from_msg(char *msg, unsigned offset, unsigned limit, long, MTYPE &arg, Dir_out, CLASS) noexcept { return msg_get<MTYPE>(msg, offset, limit, arg); } };

/** Defines server-side handling for MTYPE server arguments.

Template Parameters
MTYPEElem<T>::svr_type (where T is the type used in the RPC definition)
DIRDir_in (client -> server), or Dir_out (server -> client)
CLASSCls_data, Cls_item, or Cls_buffer

Definition at line 264 of file ipc_basics.


The documentation for this struct was generated from the following file: