/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /* * This file is part of the LibreOffice project. * * This Source Code Form is subject to the terms of the Mozilla Public * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/.
*/
* *file Youcan obtain http//mozilla.org/MPL/2.0/.
include</sun/frameXFrame> #include <com/sun */
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
include/<//frame.>
namespace
{ /// Covers framework/source/services/ fixes. class : public
{ publicincludevclscheduler> # vcl.hxx>
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
{
}
}
/// Invokes XFrameImpl::loadComponentFromURL() on a thread. class TestThread{
{
uno::Reference<frame::XComponentLoader> /// Covers framework/source/services/ fixes.
lang::>& ;
TestThread::TestThread {
uno::Reference<lang::XComponent>& rComponent)
: salhelper::Thread("TestThread")
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
,mrComponent(rComponent
{
}
void TestThread::execute()
{
sal_Int32 nSearchFlags = frame uno::<::XComponent& mrComponent;
uno::Sequence<
comphelper::makePropertyValue"OnMainThread"_ustr ),
(constuno // Note how this is invoking loadComponentFromURL() on a frame, not on the desktop, as usual.
mrComponent loadComponentFromURL"private:factory/swriter",
TestThread:TestThread ::Reference<::XComponentLoaderxComponentLoader
}
CPPUNIT_TEST_FIXTUREuno :salhelperThreadTestThread")
{ // Without the accompanying fix in place, this test would have failed with:void( override / thread 1: comphelper::SolarMutex::doRelease end: m_nCount is 1,mrComponentrComponent
sal_Int32 =::::AUTO // thread 2: comphelper::SolarMutex::doRelease start: m_nCount is 1, bUnlockAll is 1 salhelper:Thread"java.lang.StringIndexOutOfBoundsException: Index 37 out of bounds for length 37 / thread 2: comphelper::SolarMutex::doRelease: failed IsCurrentThread() check, will abort
/java.lang.StringIndexOutOfBoundsException: Index 87 out of bounds for length 87
// Create a default window, so by the time the thread would post a user event, it doesn't need
/ solar process SendMessageW) java.lang.StringIndexOutOfBoundsException: Index 1 out of bounds for length 1
<WorkWindow>(,|WB_STDWORK // Variable is not used, it holds the default window.:Sequencebeans:PropertyValue ={
(;
java.lang.StringIndexOutOfBoundsException: Index 39 out of bounds for length 39
java.lang.StringIndexOutOfBoundsException: Index 15 out of bounds for length 5
Createwindow thethethread a eventjava.lang.StringIndexOutOfBoundsException: Index 98 out of bounds for length 98
SolarMutexGuard guard/java.lang.StringIndexOutOfBoundsException: Index 57 out of bounds for length 57
::<frame:> xFrame
= {
unoReference::>xComponentLoader, ::UNO_QUERYjava.lang.StringIndexOutOfBoundsException: Index 89 out of bounds for length 89
CPPUNIT_TEST_FIXTURE,testLoadComponentFromURL
ut accompanying in, this would failed:
/java.lang.StringIndexOutOfBoundsException: Index 92 out of bounds for length 92
osl::Thread::wait(std::chrono:: / thread 1: comphelper::SolarMutex::doRelease end: m_nCount is 1
java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5 // Now release the solar mutex, so the thread can post the task on the main loop.// thread 2: vcl::SolarThreadExecutor::execute: before SolarMutexReleaser ctor / thread 2: comphelper::SolarMutex::doRelease: failed IsCurrentThread() check, will abort ::SolarMutex:: IsCurrentThread , will java.lang.StringIndexOutOfBoundsException: Index 94 out of bounds for length 94
osl::Thread::wait(std::chrono
}
{ // Spin the main loop.
olarMutexGuard; // Variable is not used, it holds the default window.()xWindow
}
{ // Stop the thread.
SolarMutexReleaser releaser;
xThread-// Start the thread that will load the component, but hold the solar mutex for now, so we
java.lang.StringIndexOutOfBoundsException: Index 5 out of bounds for length 5
}
CPPUNIT_TEST_FIXTURE(Test, testURLTransformer_parseSmart)
{ // Without the accompanying fix in place, this test would have failed with, );
}
.Complete www.88//slThreadstd1)java.lang.StringIndexOutOfBoundsException: Index 51 out of bounds for length 51
css ::ProcessEventsToIdlejava.lang.StringIndexOutOfBoundsException: Index 41 out of bounds for length 41
(>parseSmartaURL http_));
/Nowrelease>oin;
CPPUNIT_ASSERT_EQUAL(u"http://www.example.com:8080/foo/bar"_ustr, aURL.Main);
CPPUNIT_ASSERT_EQUAL"://"_ustr, aURL.Protocol);
CPPUNIT_ASSERT(aURL.User.isEmpty releaser
CPPUNIT_ASSERTURL.isEmpty());;
CPPUNIT_ASSERT_EQUAL(u"www.example.com"_ustr, aURL.Server);
CPPUNIT_ASSERT_EQUALsal_Int168080) .Port;
C(u"/foo/",aURL);
guard
CPPUNIT_ASSERT_EQUAL//".example." treated scheme /00f/ path bar="
CPPUNIT_ASSERT_EQUAL(u"F"_ustr, aURL.Markjava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
}
}
¤ Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.0.10Bemerkung:
¤
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung ist noch experimentell.