summaryrefslogtreecommitdiff
path: root/sax
AgeCommit message (Collapse)AuthorFilesLines
2016-08-16loplugin:stringstaticStephan Bergmann1-15/+15
Change-Id: I3812abe3b275bc1b89e340d0e8f52aa1d67905e8
2016-08-10GSoC - Making legacyfastparser to use tokens:Mohammed Abdul Azeem3-54/+206
This tokenizes some elements, de-tokenize while consuming and emits elements through legacy interface. DummyTokenHandler is just to test the correctness. Change-Id: I1ea1e4d806ed4d426215f93b3f6b66a9776f6479 Reviewed-on: https://gerrit.libreoffice.org/27849 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-08-08Related: tdf#99312, add specialized interaction handlerGiuseppe Castagno1-0/+1
Needed to manage https certificates and authentication whenever needed. Change-Id: If20b85a9b349b203a8c46d453afa823629d114cb Reviewed-on: https://gerrit.libreoffice.org/27927 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Giuseppe Castagno <giuseppe.castagno@acca-esse.eu>
2016-08-05loplugin:countusersofdefaultparams in oox..sdNoel Grandin1-2/+2
Change-Id: I4504939a3957606979c6ac36af6611e1fe072d01 Reviewed-on: https://gerrit.libreoffice.org/27902 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-07-29GSoC - moving FastAttributeList::clear to consumer thread:Mohammed Abdul Azeem1-8/+42
this shares the load of clearing the attributes list with the consumer when producer is busy. Change-Id: I6e89858703c7af9c30b2d99fd6825dc81290b488 Reviewed-on: https://gerrit.libreoffice.org/27649 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2016-07-27GSOC - Avoid tokenizing strings for Unknown elements:Mohammed Abdul Azeem2-58/+67
Added a special case when token handler is not set, which avoids tokenizing strings. Change-Id: I749a7af22e45180cc8bfc55843832b7ccb529ac6 Reviewed-on: https://gerrit.libreoffice.org/27593 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Michael Meeks <michael.meeks@collabora.com>
2016-07-19GSOC - Handling namespace declaration missing case:Mohammed Abdul Azeem5-5/+82
initialization parameter to FastParser will turn off the namespace declaration missing exception. Test cases have also been given to verify the same. Change-Id: I4c3e02c7ad92d50e279f895ced53c78fc8f49b91 Reviewed-on: https://gerrit.libreoffice.org/27278 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Michael Meeks <michael.meeks@collabora.com>
2016-07-17loplugin:passstuffbyrefStephan Bergmann1-1/+1
Change-Id: I7c8cd99210d1048b73e074831080e9c7121292fc
2016-07-16GSoC - Sync namespace handler calls with elements:Mohammed Abdul Azeem3-5/+31
This syncs the namespace declaration calls with element's events. A test case is also added which enables threads of fastparser. Change-Id: Ic40a380c8523688ee6b2ec76bb3d36a0452923bd Reviewed-on: https://gerrit.libreoffice.org/27222 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Michael Meeks <michael.meeks@collabora.com>
2016-07-15new loplugin unnecessary overrideNoel Grandin1-0/+1
Change-Id: I88d3e33823d68745b98625050a8a274f9ef04bcb Reviewed-on: https://gerrit.libreoffice.org/27135 Reviewed-by: Stephan Bergmann <sbergman@redhat.com> Tested-by: Stephan Bergmann <sbergman@redhat.com>
2016-07-10loplugin:unreffunStephan Bergmann1-1/+0
Change-Id: I8649e6bbe3b5c1189ef3c07bcbc1c2155d265b59
2016-07-09GSOC: Adapt XLegacyFastParser to function like XParser.Mohammed Abdul Azeem3-175/+121
Made XFastParser to pass namespace prefix instead of URI for Unknown attributes and elements, Namespace handler is provided to resolve those. Test for XFastParser unknown elements is removed, since testing XLegacyFastParser indirectly tests that also. Change-Id: Ia41ff5d3d4c07cef0ca23ba858bfb2a94b91b1f5 Reviewed-on: https://gerrit.libreoffice.org/26982 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2016-07-08loplugin:staticmethodsStephan Bergmann1-27/+22
Change-Id: Ia9a3b93df2c885a56705b35b88fe0a8f50a10b74
2016-07-08GSOC: Added test case for mishandle of namespaces.Mohammed Abdul Azeem1-0/+78
Added a test case for misuse of namespace declaration and resolving an element name. Change-Id: Iadda81a82353de45418fff6315c2d9b94626126a Reviewed-on: https://gerrit.libreoffice.org/26661 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2016-07-08loplugin:redundantcast: redundant static_casts in saxStephan Bergmann1-1/+1
Change-Id: I8f9398a0d6e362c8f786e17e63ec48e4c4f77866
2016-07-07loplugin:passstuffbyref also for {css::uno,rtl}::ReferenceStephan Bergmann2-2/+2
Change-Id: If18f0a749c1e474c302fd797c2a2abc2b33a0730
2016-07-04use SAL_DEPRECATED in uno::ReferenceNoel Grandin1-1/+1
and fix a couple of usages that have crept in Change-Id: Ia3e7fcc05dac6e0d205e69c0e0372c74653e7c5e Reviewed-on: https://gerrit.libreoffice.org/26851 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-06-17loplugin:refcountingStephan Bergmann1-6/+6
Change-Id: I39fbc89cffe25e85b8cd1f2e36f0a20c07e33497
2016-06-17loplugin:passstuffbyrefStephan Bergmann1-1/+1
Change-Id: I2fb13854a6da3f114dba386169e5aef7f741b922
2016-06-17GSoC: Mapping legacy sax parser and XFastParserMohammed Abdul Azeem4-8/+325
This implements legacy parser interface using XFastParser, and unit test is also added. Change-Id: Ia2eb7d517d80a3f7ec0cf26ffa2e5747ad22b186 Reviewed-on: https://gerrit.libreoffice.org/26229 Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Tested-by: Michael Meeks <michael.meeks@collabora.com>
2016-06-16loplugin:refcountingStephan Bergmann1-4/+4
Change-Id: Iafc3987df4357098aab816fb7fd4619f9a6ee173
2016-06-15GSoC: sax2/ unit tests:Mohammed Abdul Azeem3-41/+190
Parsed the same test files using XFastParser and built string, we asssert that both the strings built from XParser and XFastParser are identical. Change-Id: Ie1e0dc6b676ca32dd10d75c3cb272b5c8b795ab7
2016-06-09tdf#94698 cleanup Makefiles. Get rid of udkapi and offapiGleb Mishchenko1-4/+1
This patch changes occurences in makefiles from $(eval $(call gb_CppunitTest_use_api,comphelper_test_config, \ udkapi \ offapi \ )) to $(eval $(call gb_CppunitTest_use_sdk_api,comphelper_test_config)) (corrected instead of abandon, jani) Change-Id: Ic96ec65d82d7452e288f05a8b6d576ef543b068e Reviewed-on: https://gerrit.libreoffice.org/23426 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: jan iversen <jani@documentfoundation.org> Tested-by: jan iversen <jani@documentfoundation.org>
2016-06-08Let loplugin:passstuffbyref also look at fn defn not preceded by any declStephan Bergmann2-2/+2
Change-Id: I752bc96d2d521d790e919283cabb14b6526626f4
2016-05-31teach refcounting clang plugin about uno::ReferenceNoel Grandin3-5/+6
uno::Reference is only allowed to used with classes that have a ::static_type member. So convert all those places to rtl::Reference. Maybe we need some LIBO_INTERNAL_ONLY constructors on rtl::Reference and uno::Reference to make this a little smoother? Change-Id: Icdcb35d71ca40a87b1dc474096776412adbfc7e3 Reviewed-on: https://gerrit.libreoffice.org/25516 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-05-29loplugin:unreffunStephan Bergmann1-1/+0
Change-Id: I31e62926ddfddc8bbdab681a55cdc381d3275794
2016-05-28sax2/ unit tests.Mohammed Abdul Azeem10-33/+197
Test xml files are added, string is built for each file and namespaces are handled. Change-Id: I0ab799ca5c9de7311ccca2a6033a96e02598064f Reviewed-on: https://gerrit.libreoffice.org/25468 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
2016-05-22-Werror,-Wunused-private-fieldStephan Bergmann1-1/+1
Change-Id: I286afa5f5f849217c282c8408822522d9ce5a10b
2016-05-19loplugin:unreffun and loplugin:nullptrNoel Grandin1-2/+2
Change-Id: I0b8e094d5f5db4b9add46894c4a606256c2d6904 Reviewed-on: https://gerrit.libreoffice.org/25159 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
2016-05-19First cut at adding sax2/ unit tests.Mohammed Abdul Azeem5-0/+243
This is a first-step towards implementing the legacy parser using the XFastParser. Change-Id: I37fc0419dbef1d6f067e45e0b1f2fd6051fb158d Reviewed-on: https://gerrit.libreoffice.org/24883 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-05-10Replace fallthrough comments with new SAL_FALLTHROUGH macroStephan Bergmann1-2/+2
...which (in LIBO_INTERNAL_ONLY) for Clang expands to [[clang::fallthrough]] in preparation of enabling -Wimplicit-fallthrough. (This is only relevant for C++11, as neither C nor old C++ has a way to annotate intended fallthroughs.) Could use BOOST_FALLTHROUGH instead of introducing our own SAL_FALLTHROUGH, but that would require adding back in dependencies on boost_headers to many libraries where we carefully removed any remaining Boost dependencies only recently. (At least make SAL_FALLTHROUGH strictly LIBO_INTERNAL_ONLY, so its future evolution will not have any impact on the stable URE interface.) C++17 will have a proper [[fallthroug]], eventually removing the need for a macro altogether. Change-Id: I342a7610a107db7d7a344ea9cbddfd9714d7e9ca
2016-05-05clang-tidy modernize-loop-convert in oox to saxNoel Grandin2-5/+5
Change-Id: If0d87b6679765fc6d1f9300c6972845cf3742b9c Reviewed-on: https://gerrit.libreoffice.org/24674 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
2016-05-04tdf#94260 Convert pixel to 1/100 mmRosemary Sebastian1-9/+15
The scaling factor 0.28 is chosen as per https://www.w3.org/TR/2001/REC-xsl-20011015/slice5.html#pixels Change-Id: I8dc7846699fbb2aa6e2a181a041b66d3cc33b8e5 Reviewed-on: https://gerrit.libreoffice.org/24547 Reviewed-by: Oliver Specht <oliver.specht@cib.de> Tested-by: Oliver Specht <oliver.specht@cib.de>
2016-04-21loplugin:salbool: sal_Bool[] -> bool[]Stephan Bergmann1-6/+6
Change-Id: I3c5bf7a53c9ae173f8fce885ecf022f092aa43a9
2016-04-20loplugin:salbool: Automatic rewrite of sal_False/TrueStephan Bergmann2-3/+3
Change-Id: I923b1b92f07c2db6d88c7682f1733fd8fd765f90
2016-04-18clean-up: unused using declarations and includesJochen Nitschke1-1/+0
Searched source for using declarations. Checked if those symbols reappear in the source file, even in comments or dead code but not in #include statements. If they don't reappear, remove the declaration. Remove includes whose symbol got removed. Change-Id: Ibb77163f63c1120070e9518e3dc0a78c6c59fab0 Reviewed-on: https://gerrit.libreoffice.org/24148 Reviewed-by: Jochen Nitschke <j.nitschke+logerrit@ok.de> Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
2016-04-13loplugin:passstuffbyref in saxNoel Grandin1-1/+1
Change-Id: I95f0a17b9b8bab592a60f6b5223b4668c5355275
2016-04-12cleanup: remove unused com/sun/star/uno includesJochen Nitschke1-1/+0
Sequence.h(xx), Any.h(xx) and Type.h(xx) and remove unused using-declarations from these files. Add a few missing includes provided by them. Change-Id: I6b91b6d1fdf9d0496dd546c0aab9bdcc6831a5d4 Reviewed-on: https://gerrit.libreoffice.org/23805 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-04-11clang-tidy performance-unnecessary-value-param in saxNoel Grandin1-2/+2
Change-Id: I46aad7b0a96210e5f3f278c3f6f3a945825b7cae
2016-04-04tdf#97499 Fixed containers parameters clearing #4tymyjan1-1/+1
Change-Id: I7c96181399f4d7e62d4aceca404b22d68f903513 Reviewed-on: https://gerrit.libreoffice.org/23754 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-04-01tdf#97966 Drop 'static' keywordsWastack2-9/+9
Including no keywords from extern "C" blocks Change-Id: I87f2ed75888b51ec9e0cb75566bf7c2351b479b4 Reviewed-on: https://gerrit.libreoffice.org/23675 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2016-03-08tdf#97703 Removed empty setUp/tearDown methodsChirag Manwani1-10/+0
Change-Id: Ia62de30ae94bdae87cd5109c44eab40af4d020e5 Reviewed-on: https://gerrit.libreoffice.org/22985 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
2016-03-04tdf#96505 Remove long integer literal specifier when not neededAleksas Pantechovskis1-2/+2
Remove L from integer literals if it does not produce warnings and does not change semantics Change-Id: I9573a47d3e3401993a1f0fbcf7df4be20f9e6eba Reviewed-on: https://gerrit.libreoffice.org/22867 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
2016-02-15Rename rtl::isValidCodePoint -> rtl::isUnicodeCodePointStephan Bergmann1-2/+3
...and fix its documentation, and use it throughout the code base. Change-Id: I349bc2009b1b0aa7115ea90bc6ecd0a812f63698
2016-02-09Remove excess newlinesChris Sherlock6-37/+0
A ridiculously fast way of doing this is: for i in $(pcregrep -l -M -r --include='.*[hc]xx$' \ --exclude-dir=workdir --exclude-dir=instdir '^ {3,}' .) do perl -0777 -i -pe 's/^ {3,}/ /gm' $i done Change-Id: Iebb93eccbee9e4fc5c4380474ba595858a27ac2c Reviewed-on: https://gerrit.libreoffice.org/22224 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Chris Sherlock <chris.sherlock79@gmail.com>
2016-02-06sax: Use comphelper's AttributeListMatúš Kukan4-244/+6
Change-Id: I6eb0115dba8797025a513cf1e6cfbfbe0b6f7e50
2016-02-03fix gcc build errorCaolán McNamara1-2/+2
error: invalid operands of types '__gnu_cxx::__enable_if<true, double>::__type {aka double}' and 'int' to binary 'operator%' apparently there's a template returning double for abs for the non-int/long/float/double argument case. So promote earlier to int so the abs<int> is called Change-Id: I882a27c5ec349f894c1c9f4857687360a46b55ae
2016-01-20loplugin:unusedmethodsNoel Grandin1-29/+0
Change-Id: Ib2dc804f55d1a96ae01f2cf31b7d55956040a72e Reviewed-on: https://gerrit.libreoffice.org/21603 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
2016-01-17crashtesting: plain-text import allows liberal with the UTF-8 inputCaolán McNamara1-1/+1
see ImplConvertUtf8ToUnicode which allows surrogates, so we need a non-liberal utf-input there if we want to enfore non-liberal utf-output here. Change-Id: I713818d7b6d79922d9b08f2b137a803384eccb65
2016-01-17sax: use CPPUNIT_ASSERT_THROWMatúš Kukan2-20/+2
Change-Id: I34b0b559a91e77cc497e14d8ffad7e2c80e43d79 Reviewed-on: https://gerrit.libreoffice.org/21531 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Matúš Kukan <matus@libreoffice.org>