19#ifndef INCLUDED_TOOLS_INETMSG_HXX 
   20#define INCLUDED_TOOLS_INETMSG_HXX 
   23#include <rtl/string.hxx> 
   24#include <rtl/ustring.hxx> 
   33#include <config_options.h> 
   63    const OString& 
GetValue()
 const { 
return m_aValue; }
 
   77    ::std::vector< std::unique_ptr<INetMessageHeader> >
 
   82    ::std::map<InetMessageMime, sal_uInt32>   m_nMIMEIndex;
 
   83    INetMIMEMessage*                          pParent;
 
   84    ::std::vector< std::unique_ptr<INetMIMEMessage> >
 
   88    OUString GetHeaderValue_Impl (
 
   91        if ( 
nIndex < m_aHeaderList.size() ) {
 
   98    void SetHeaderField_Impl (
 
  102        if (m_aHeaderList.size() <= rnIndex)
 
  104            rnIndex = m_aHeaderList.size();
 
  105            m_aHeaderList.emplace_back( 
p );
 
  109            m_aHeaderList[ rnIndex ].reset(
p);
 
  113    void SetHeaderField_Impl (
 
  114        const OString &rName,
 
  115        const OUString &rValue,
 
  116        sal_uInt32 &rnIndex);
 
  118    bool IsMessage()
 const 
  120        OUString aType (GetContentType());
 
  121        return aType.matchIgnoreAsciiCase(
"message/");
 
  124    INetMIMEMessage (
const INetMIMEMessage& rMsg) = 
delete;
 
  125    INetMIMEMessage& operator= (
const INetMIMEMessage& rMsg) = 
delete;
 
  131    sal_uInt32 GetHeaderCount()
 const { 
return m_aHeaderList.size(); }
 
  135        if ( 
nIndex < m_aHeaderList.size() ) {
 
  136            return *m_aHeaderList[ 
nIndex ];
 
  142    SvLockBytes* GetDocumentLB()
 const { 
return m_xDocLB.get(); }
 
  143    void         SetDocumentLB (
SvLockBytes *pDocLB) { m_xDocLB = pDocLB; }
 
  145    static bool ParseDateField (
 
  146        std::u16string_view rDateField, 
DateTime& rDateTime);
 
  148    void     SetMIMEVersion (
const OUString& rVersion);
 
  149    void     SetContentDisposition (
const OUString& rDisposition);
 
  150    void     SetContentType (
const OUString& rType);
 
  151    OUString GetContentType()
 const 
  153        return GetHeaderValue_Impl(
 
  157    void     SetContentTransferEncoding (
const OUString& rEncoding);
 
  159    OUString GetDefaultContentType ();
 
  163    bool IsContainer()
 const 
  165        return (IsMessage() || IsMultipart());
 
  167    bool IsMultipart()
 const 
  169        OUString aType (GetContentType());
 
  170        return aType.matchIgnoreAsciiCase(
"multipart/");
 
  173    INetMIMEMessage* GetChild (sal_uInt32 
nIndex)
 const 
  175        return ( 
nIndex < aChildren.size() ) ? aChildren[ 
nIndex ].get() : 
nullptr;
 
  177    INetMIMEMessage* GetParent()
 const { 
return pParent; }
 
  179    void EnableAttachMultipartFormDataChild();
 
  180    void AttachChild( std::unique_ptr<INetMIMEMessage> pChildMsg );
 
  182    const OString& GetMultipartBoundary()
 const { 
return m_aBoundary; }
 
static OUString decodeHeaderFieldBody(const OString &rBody)
 
@ CONTENT_TRANSFER_ENCODING
 
class SAL_WARN_UNUSED UNLESS_MERGELIBS(TOOLS_DLLPUBLIC) INetMIMEMessage