• Home
  • History
  • Annotate
Name Date Size #Lines LOC

..03-May-2022-

inc/pch/H03-Mar-2022-140103

qa/H03-Mar-2022-4,7313,608

source/H03-Mar-2022-46,70836,140

unx/source/svdde/H03-Mar-2022-331244

util/H03-Mar-2022-3516

AllLangMoTarget_svl.mkH A D03-Mar-2022401 121

CppunitTest_svl_adrparse.mkH A D03-Mar-2022615 228

CppunitTest_svl_inetcontenttype.mkH A D03-Mar-2022794 3115

CppunitTest_svl_itempool.mkH A D03-Mar-2022870 3518

CppunitTest_svl_items.mkH A D03-Mar-2022791 3115

CppunitTest_svl_lngmisc.mkH A D03-Mar-2022878 3720

CppunitTest_svl_lockfiles.mkH A D03-Mar-20221.3 KiB5532

CppunitTest_svl_notify.mkH A D03-Mar-2022852 3417

CppunitTest_svl_qa_cppunit.mkH A D03-Mar-20221.7 KiB6335

CppunitTest_svl_urihelper.mkH A D03-Mar-20221 KiB4223

IwyuFilter_svl.yamlH A D03-Mar-20222 KiB5352

JunitTest_svl_complex.mkH A D03-Mar-20221.8 KiB5023

Library_fsstorage.mkH A D03-Mar-20221.6 KiB5123

Library_passwordcontainer.mkH A D03-Mar-20221.6 KiB4820

Library_svl.mkH A D03-May-20225.3 KiB201166

MakefileH A D03-Mar-2022225 82

Module_svl.mkH A D03-Mar-20221.6 KiB5323

README.mdH A D03-Mar-20222.1 KiB5236

README.md

1# Non-Graphical Helper Code (svtools light)
2
3Contains non-graphical helper code for office applications.
4
5Specifically this module does not depend on or use includes from module
6vcl. Originally all code in svtools that did not depend on vcl was split
7off into this svl ("svtools light") module.
8
9In particular the `SfxItemSet` is a property-bag like container that
10stores arbitrary sets of properties for everything from text run
11formats, to Chart regression line properties.
12
13There are lots of other useful helpers in here for various office
14tasks; much of this code was originally moved from `svx/sfx2`.
15
16## Items, Pools and Sets
17
18### SfxPoolItem
19
20A small reference counted piece of data.  Many subclasses, each with a
21unique integer to identify its type (`WhichId`).  Can be compared for equality
22(`operator==`), `Clone()`d, and converted to/from `uno::Any` (`QueryValue/PutValue`).
23
24A pool item may have value semantics ("poolable"), meaning that
25there will generally be only one instance that compares equal per item pool,
26or not, in which case the item will be `Clone()`d quite a bit.
27
28### SfxItemPool
29
30Usually there is one item pool per document, with a range of valid `WhichId`s
31that is specific to the type of document.
32
33The item pool owns all instances of `SfxPoolItem` or its subclasses that have
34ever been added to an item set.  It also contains a default item for
35every WhichId, which will be (depending on parameters) returned from item
36sets if the set does not contain an item at this `WhichId`.
37
38### SfxItemSet
39
40The item set can be created with a user-supplied range of `WhichId`s; it
41will accept `SfxPoolItems` with matching `WhichId`s and ignore attempts to
42insert items with non-matching `WhichId`s.
43
44Items that are successfully inserted into the set will be stored in the
45set's `SfxItemPool`, and for poolable items only a single instance that
46compares equal under the predicate `operator==` will be stored in the pool,
47regardless of how many sets contain it, thus conserving memory.
48
49There are members `m_pWhichRanges` for the valid ranges (as pairs of `WhichId`s),
50`m_nCount` for the number of items contained, and `m_pItems` for the pointers to
51the actual items.
52