title: Should I delete the string members of a C++ class?
body: <p>If I have the following declaration:</p>
  
  <pre><code>#include &lt;iostream&gt;
  #include &lt;string&gt;
  
  class DEMData
  {
  private:
      int bitFldPos;
      int bytFldPos;
      std::string byteOrder;
      std::string desS;
      std::string engUnit;
      std::string oTag;
      std::string valType;
      int idx;
  public:
      DEMData();
      DEMData(const DEMData &amp;d);
      void SetIndex(int idx);
      int GetIndex() const;
      void SetValType(const char* valType);
      const char* GetValType() const;
      void SetOTag(const char* oTag);
      const char* GetOTag() const;
      void SetEngUnit(const char* engUnit);
      const char* GetEngUnit() const;
      void SetDesS(const char* desS);
      const char* GetDesS() const;
      void SetByteOrder(const char* byteOrder);
      const char* GetByteOrder() const;
      void SetBytFldPos(int bytFldPos);
      int GetBytFldPos() const;
      void SetBitFldPos(int bitFldPos);
      int GetBitFldPos() const;
      friend std::ostream &amp;operator&lt;&lt;(std::ostream &amp;stream, DEMData d);
      bool operator==(const DEMData &amp;d) const;
      ~DEMData();
  };
  </code></pre>
  
  <p>what code should be in the destructor?  Should I "delete" the <code>std::string</code> fields?</p>