LibreOffice Module sw (master) 1
|
The following class is a wrapper for basic i/o functions of Writer 3.0. More...
#include <iodetect.hxx>
Static Public Member Functions | |
static SW_DLLPUBLIC std::shared_ptr< const SfxFilter > | GetFilterOfFormat (std::u16string_view rFormat, const SfxFilterContainer *pCnt=nullptr) |
find for an internal format name the corresponding filter entry More... | |
static std::shared_ptr< const SfxFilter > | GetFileFilter (const OUString &rFileName) |
Detect for the given file which filter should be used. More... | |
static bool | IsValidStgFilter (SotStorage &, const SfxFilter &) |
static bool | IsValidStgFilter (const css::uno::Reference< css::embed::XStorage > &rStg, const SfxFilter &rFilter) |
static SW_DLLPUBLIC rtl_TextEncoding | GetTextEncoding (SvStream &) |
static bool | IsDetectableText (const char *pBuf, sal_uLong &rLen, rtl_TextEncoding *pCharSet, bool *pSwap, LineEnd *pLineEnd, bool *pBom) |
static OUString | GetSubStorageName (const SfxFilter &rFltr) |
The following class is a wrapper for basic i/o functions of Writer 3.0.
Everything is static. All filter names mentioned are Writer-internal names, i.e. the names in front of the equality sign in INSTALL.INI, like SWG or ASCII.
Definition at line 93 of file iodetect.hxx.
|
static |
Detect for the given file which filter should be used.
The filter name is returned. If no filter could be found, the name of the ASCII filter is returned!
Definition at line 149 of file iodetect.cxx.
References ERRCODE_NONE, FILTER_TEXT, SfxFilterMatcherIter::First(), GetFilterOfFormat(), SfxMedium::GetInStream(), INetURLObject::GetMainURL(), SfxFilterContainer::GetName(), SfxMedium::GetStorage(), tools::SvRef< typename T >::is(), IsDocShellRegistered(), SfxMedium::IsStorage(), SotStorage::IsStorageFile(), IsValidStgFilter(), SfxFilterMatcherIter::Next(), INetURLObject::NONE, INetURLObject::SetSmartProtocol(), INetURLObject::SetSmartURL(), sSWRITER, and sSWRITERWEB.
Referenced by SwDBManager::MergeMailFiles(), and SwTransferable::PasteFileName().
|
static |
find for an internal format name the corresponding filter entry
Definition at line 68 of file iodetect.cxx.
References SfxFilterMatcherIter::First(), SfxFilterContainer::GetName(), IsDocShellRegistered(), SfxFilterMatcherIter::Next(), sSWRITER, and sSWRITERWEB.
Referenced by SwXMailMerge::execute(), SwDocShell::Execute(), GetFileFilter(), IMPL_LINK_NOARG(), and SwDoc::SplitDoc().
|
static |
Definition at line 55 of file iodetect.cxx.
References FILTER_WW8, FILTER_XML, FILTER_XMLV, FILTER_XMLVW, SfxFilter::GetUserData(), and sWW6.
Referenced by IsValidStgFilter().
|
static |
Definition at line 241 of file iodetect.cxx.
References aBuf, IsDetectableText(), SvStream::ReadBytes(), rStrm, and SvStream::SeekRel().
Referenced by SwEditShell::ApplyAutoMark().
|
static |
Definition at line 257 of file iodetect.cxx.
References GetSystemLineEnd(), LINEEND_CR, LINEEND_CRLF, LINEEND_LF, match(), and n.
Referenced by GetTextEncoding().
|
static |
Definition at line 95 of file iodetect.cxx.
References SfxFilter::GetFormat(), and SotStorage::GetFormatID().
|
static |
Definition at line 112 of file iodetect.cxx.
References ERRCODE_NONE, FILTER_WW8, SotStorage::GetError(), SotStorage::GetFormat(), SfxFilter::GetFormat(), GetSubStorageName(), SfxFilter::GetUserData(), SfxFilter::IsAllowedAsTemplate(), SotStorage::IsContained(), SotStorage::OpenSotStream(), and sWW6.
Referenced by GetFileFilter().