25#include <osl/diagnose.h>
41 aB2DPolyPolygon(
std::move(_aB2DPolyPolygon))
47 aB2DPolyPolygon(rOther.aB2DPolyPolygon)
83 aGradient(rOther.aGradient)
89 maGraphicObject(rGraphicObject)
95 maGraphicObject(rOther.maGraphicObject)
101 OUString aPath, OUString aReferer
105 maReferer (
std::move( aReferer )),
106 mbListDirty ( true ),
107 mbEmbedInDocument( false )
182 assert(!
"empty XPropertyEntry not allowed in XPropertyList");
189 maList.push_back( std::move(pEntry) );
197 assert(!
"empty XPropertyEntry not allowed in XPropertyList");
202 assert(!
"trying to replace invalid entry in XPropertyList");
213 assert(!
"trying to remove invalid entry in XPropertyList");
222 if(!rString.isEmpty())
233 std::stack<OUString> aDirs;
244 while (!aDirs.empty())
246 OUString aPath(aDirs.top());
251 if( INetProtocol::NotValid ==
aURL.GetProtocol() )
259 if(
aURL.getExtension().isEmpty() )
263 maReferer, uno::Reference < embed::XStorage >(),
273 const OUString &rURL,
const OUString &rReferer )
294 if( INetProtocol::NotValid ==
aURL.GetProtocol() )
296 DBG_ASSERT( aLastDir.isEmpty(),
"invalid URL" );
302 if(
aURL.getExtension().isEmpty() )
307 uno::Reference< embed::XStorage >(),
nullptr );
311 const OUString &rURL, OUString *pOptName )
317 const OUString& rPath,
318 const OUString& rReferer )
345 OSL_FAIL(
"unknown xproperty type");
348 OSL_ASSERT( !pRet.is() || pRet->meType == aType );
355 std::u16string_view rURLStr )
365 pList->SetName(
aURL.getName() );
388 return OUString::createFromAscii(
i.pExt );
OUString GetMainURL(DecodeMechanism eMechanism, rtl_TextEncoding eCharset=RTL_TEXTENCODING_UTF8) const
bool removeSegment(sal_Int32 nIndex=LAST_SEGMENT, bool bIgnoreFinalSlash=true)
static bool save(const OUString &rURL, const css::uno::Reference< css::container::XNameContainer > &xTable, const css::uno::Reference< css::embed::XStorage > &xStorage, OUString *pOptName)
static bool load(const OUString &rPath, const OUString &rReferer, const css::uno::Reference< css::embed::XStorage > &xStorage, const css::uno::Reference< css::container::XNameContainer > &xTable, bool *bOptLoadedFromStorage) noexcept
XBitmapEntry(const GraphicObject &rGraphicObject, const OUString &rName)
XColorEntry(const Color &rColor, const OUString &rName)
XDashEntry(const XDash &rDash, const OUString &rName)
XGradientEntry(const basegfx::BGradient &rGradient, const OUString &rName)
XHatchEntry(const XHatch &rHatch, const OUString &rName)
XLineEndEntry(basegfx::B2DPolyPolygon aB2DPolyPolygon, const OUString &rName)
void SetUiBitmap(const BitmapEx &rUiBitmap)
const BitmapEx & GetUiBitmap() const
virtual ~XPropertyList() override
bool LoadFrom(const css::uno::Reference< css::embed::XStorage > &xStorage, const OUString &rURL, const OUString &rReferer)
BitmapEx GetUiBitmap(tools::Long nIndex) const
static XPropertyListRef CreatePropertyList(XPropertyListType t, const OUString &rPath, const OUString &rReferer)
bool SaveTo(const css::uno::Reference< css::embed::XStorage > &xStorage, const OUString &rURL, OUString *pOptName)
bool isValidIdx(tools::Long nIndex) const
XPropertyList(XPropertyListType t, OUString aPath, OUString aReferer)
virtual css::uno::Reference< css::container::XNameContainer > createInstance()=0
std::vector< std::unique_ptr< XPropertyEntry > > maList
tools::Long GetIndex(std::u16string_view rName) const
virtual BitmapEx CreateBitmapForUI(tools::Long nIndex)=0
tools::Long Count() const
static XPropertyListRef CreatePropertyListFromURL(XPropertyListType t, std::u16string_view rUrl)
const OUString & GetName() const
void SetName(const OUString &rString)
void Insert(std::unique_ptr< XPropertyEntry > pEntry, tools::Long nIndex=std::numeric_limits< tools::Long >::max())
OUString GetDefaultExt() const
void Replace(std::unique_ptr< XPropertyEntry > pEntry, tools::Long nIndex)
void Remove(tools::Long nIndex)
XPropertyEntry * Get(tools::Long nIndex) const
#define DBG_ASSERT(sCon, aError)
constexpr std::enable_if_t< std::is_signed_v< T >, std::make_unsigned_t< T > > make_unsigned(T value)
rtl::Reference< class XPropertyList > XPropertyListRef