proxy

Proxy 3 Specifications

This document provides the API specifications for the C++ library Proxy (version 3). All the documented concepts, classes, and functions are defined in the namespace pro. Unless otherwise specified, all facilities are freestanding by default.

Concepts

Name Description
facade Specifies that a type models a “facade”
proxiable Specifies that a pointer type can instantiate a proxy
inplace_proxiable_target Specifies that a value type can instantiate a proxy without allocation

Classes

Name Description
proxy Wraps a pointer object matching specified facade
basic_facade_builder
facade_builder
Provides capability to build a facade type at compile-time
constraint_level Defines the 4 constraint levels of a special member function
proxiable_ptr_constraints Defines the constraints of a pointer type to instantiate a proxy
operator_dispatch Dispatch type for operator expressions with accessibility
conversion_dispatch Dispatch type for conversion expressions with accessibility

Functions

Name Description
make_proxy Creates a proxy object potentially with heap allocation
make_proxy_inplace Creates a proxy object with strong no-allocation guarantee
allocate_proxy Creates a proxy object with an allocator
proxy_invoke Invokes a proxy with a specified convention
proxy_reflect Acquires reflection information of the underlying pointer type
access_proxy Accesses a proxy object via an accessor

Macros

Name Description
PRO_DEF_MEM_DISPATCH Defines a dispatch type for member function call expressions with accessibility
PRO_DEF_FREE_DISPATCH Defines a dispatch type for free function call expressions with accessibility
PRO_DEF_WEAK_DISPATCH Defines a weak dispatch type with a default implementation
__msft_lib_proxy Feature test macro

Named Requirements

Name Description
ProBasicFacade Specifies that a type potentially models a “facade” of proxy
ProBasicConvention Specifies that a type potentially models a “convention”
ProFacade Specifies that a type models a “facade” of proxy
ProConvention Specifies that a type models a “convention”
ProReflection Specifies that a type models a “reflection”
ProDispatch Specifies that a type models a “dispatch”
ProOverload Specifies that a type models an “overload”
ProAccessible Specifies that a type provides accessibility to proxy