Go to the documentation of this file.
18 #ifndef Rcpp_macros_interface_h
19 #define Rcpp_macros_interface_h
21 #define RCPP_GENERATE_CTOR_ASSIGN(__CLASS__) \
22 typedef StoragePolicy<__CLASS__> Storage ; \
23 typedef AttributeProxyPolicy<__CLASS__> AttributePolicy ; \
24 RCPP_CTOR_ASSIGN(__CLASS__)
26 #define RCPP_CTOR_ASSIGN(__CLASS__) \
27 __CLASS__( const __CLASS__& other ){ \
28 Storage::copy__(other) ; \
30 __CLASS__& operator=(const __CLASS__& rhs) { \
31 return Storage::copy__(rhs) ; \
33 template <typename Proxy> \
34 __CLASS__( const GenericProxy<Proxy>& proxy ){ \
35 Storage::set__( proxy.get() ) ; \
38 #define RCPP_CTOR_ASSIGN_WITH_BASE(__CLASS__) \
39 __CLASS__( const __CLASS__& other ) : Base(other) { \
41 __CLASS__& operator=(const __CLASS__& rhs) { \
42 return Storage::copy__(rhs) ; \
44 template <typename Proxy> \
45 __CLASS__( const GenericProxy<Proxy>& proxy ){ \
46 Storage::set__( proxy.get() ) ; \
49 #define RCPP_API_CLASS(__CLASS__) \
50 template < template <class> class StoragePolicy > class __CLASS__ : \
51 public StoragePolicy<__CLASS__<StoragePolicy> >, \
52 public SlotProxyPolicy<__CLASS__<StoragePolicy> >, \
53 public AttributeProxyPolicy<__CLASS__<StoragePolicy> >, \
54 public RObjectMethods< __CLASS__<StoragePolicy> >