Use =default for skeleton copy constructor
[ACE_TAO.git] / TAO / tao / Utils / Encodable.h
blob5a085d8e33d849592c3326d93ef9a2a57421ee7c
1 // -*- C++ -*-
3 //=============================================================================
4 /**
5 * @file Encodable.h
7 * Defines the interface for classes that wish to be
8 * encodable/decodable into/from a CDR representation.
10 * @author Angelo Corsaro <corsaro@cs.wustl.edu>
12 //=============================================================================
14 #ifndef TAO_ENCODABLE_H_
15 #define TAO_ENCODABLE_H_
17 #include /**/ "ace/pre.h"
19 #include "tao/Basic_Types.h"
21 #if !defined (ACE_LACKS_PRAGMA_ONCE)
22 # pragma once
23 #endif /* ACE_LACKS_PRAGMA_ONCE */
25 #include "tao/Utils/utils_export.h"
27 TAO_BEGIN_VERSIONED_NAMESPACE_DECL
29 class TAO_OutputCDR;
30 class TAO_InputCDR;
32 /**
33 * @class TAO_Encodable
35 * @brief TAO_Encodable Interface
37 * This interface should be inherited by classes that wish to be
38 * encoded/decoded into/from a CDR stream. Implementation of the
39 * streaming methods is deferred to the subclasses.
41 class TAO_UTILS_Export TAO_Encodable
43 public:
44 virtual ~TAO_Encodable ();
46 /// Encodes the object implementing this method into a CDR stream.
47 /// Returns true on success and false on failure.
48 virtual CORBA::Boolean _tao_encode (TAO_OutputCDR &out_cdr) = 0;
50 /// Decodes the object implementing this method from a CDR stream.
51 /// Returns true on success and false on failure.
52 virtual CORBA::Boolean _tao_decode (TAO_InputCDR &in_cdr) = 0;
55 TAO_END_VERSIONED_NAMESPACE_DECL
57 #include /**/ "ace/post.h"
59 #endif /* TAO_ENCODABLE_H_ */