LibreOffice Module extensions (master) 1
updatecheckconfig.cxx
Go to the documentation of this file.
1/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2/*
3 * This file is part of the LibreOffice project.
4 *
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 *
9 * This file incorporates work covered by the following license notice:
10 *
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
18 */
19
20#include "updatecheckconfig.hxx"
21#include "updatecheck.hxx"
22#include <com/sun/star/beans/PropertyValue.hpp>
23#include <com/sun/star/beans/XPropertySet.hpp>
24#include <com/sun/star/configuration/theDefaultProvider.hpp>
25#include <com/sun/star/lang/XSingleServiceFactory.hpp>
27#include <osl/security.hxx>
28#include <osl/time.h>
29#include <osl/file.hxx>
30#include <sal/macros.h>
32
33#ifdef _WIN32
34#include <objbase.h>
35#include <shlobj.h>
36#endif
37
38namespace container = com::sun::star::container ;
39namespace beans = com::sun::star::beans ;
40namespace lang = com::sun::star::lang ;
41namespace util = com::sun::star::util ;
42namespace uno = com::sun::star::uno ;
43
44#define LAST_CHECK "LastCheck"
45#define UPDATE_VERSION "UpdateVersion"
46#define UPDATE_BUILDID "UpdateBuildId"
47#define UPDATE_DESCRIPTION "UpdateDescription"
48#define DOWNLOAD_URL "DownloadURL"
49#define IS_DIRECT_DOWNLOAD "IsDirectDownload"
50#define OLD_VERSION "UpdateFoundFor"
51#define AUTOCHECK_ENABLED "AutoCheckEnabled"
52#define AUTODOWNLOAD_ENABLED "AutoDownloadEnabled"
53#define CHECK_INTERVAL "CheckInterval"
54#define LOCAL_FILE "LocalFile"
55#define DOWNLOAD_SIZE "DownloadSize"
56#define DOWNLOAD_PAUSED "DownloadPaused"
57#define DOWNLOAD_DESTINATION "DownloadDestination"
58#define RELEASE_NOTE "ReleaseNote"
59
60#define PROPERTY_VERSION "Version"
61
62const char * const aUpdateEntryProperties[] = {
68 RELEASE_NOTE"1",
69 RELEASE_NOTE"2",
70 RELEASE_NOTE"3",
71 RELEASE_NOTE"4",
72 RELEASE_NOTE"5",
74};
75
77
78css::uno::Any NamedValueByNameAccess::getValue(const char * pName)
79{
80 const sal_Int32 nLen = m_rValues.getLength();
81 for( sal_Int32 n=0; n < nLen; ++n )
82 {
83 if( m_rValues[n].Name.equalsAscii( pName ) )
84 return m_rValues[n].Value;
85 }
86 return css::uno::Any();
87}
88
89bool
91{
92 return m_aNameAccess.getValue(AUTOCHECK_ENABLED).get<bool>();
93}
94
95bool
97{
98 return m_aNameAccess.getValue(DOWNLOAD_PAUSED).get<bool>();
99}
100
101OUString
103{
104 uno::Any aAny( m_aNameAccess.getValue(pStr) );
105 OUString aRet;
106
107 aAny >>= aRet;
108
109 return aRet;
110}
111
113{
115};
116
118{
120 sal_Int64 nRet = -1;
121
122 aAny >>= nRet;
123 return nRet;
124};
125
126OUString
128{
130}
131
132void
134{
138
139 bool isDirectDownload = false;
140 m_aNameAccess.getValue(IS_DIRECT_DOWNLOAD) >>= isDirectDownload;
141
142 rInfo.Sources.push_back( DownloadSource( isDirectDownload, getStringValue(DOWNLOAD_URL) ) );
143
144 for(sal_Int32 n=1; n < 6; ++n )
145 {
146 OUString aUStr = getStringValue(
147 OString(OString::Concat(RELEASE_NOTE) + OString::number(n)).getStr());
148 if( !aUStr.isEmpty() )
149 rInfo.ReleaseNotes.push_back(ReleaseNote(static_cast<sal_Int8>(n), aUStr));
150 }
151}
152
154{
155 OUString aRet;
156
157#ifdef _WIN32
158 PWSTR szPath;
159
160 if (SHGetKnownFolderPath(FOLDERID_Downloads, 0, nullptr, &szPath) == S_OK)
161 {
162 aRet = o3tl::toU(szPath);
163 CoTaskMemFree(szPath);
164 osl::FileBase::getFileURLFromSystemPath( aRet, aRet );
165 }
166#else
167 // This should become a desktop specific setting in some system backend ..
168 OUString aHomeDir;
169 osl::Security().getHomeDir( aHomeDir );
170 aRet = aHomeDir + "/Desktop";
171
172 // Set path to home directory when there is no /Desktop directory
173 osl::Directory aDocumentsDir( aRet );
174 if( osl::FileBase::E_None != aDocumentsDir.open() )
175 aRet = aHomeDir;
176#endif
177
178 return aRet;
179}
180
182{
183 OUString aRet;
184
185#ifdef _WIN32
186 WCHAR szPath[MAX_PATH];
187
188 if (TRUE == SHGetSpecialFolderPathW(nullptr, szPath, CSIDL_COMMON_DOCUMENTS, true))
189 {
190 aRet = o3tl::toU(szPath);
191 osl::FileBase::getFileURLFromSystemPath( aRet, aRet );
192 }
193#else
194 osl::FileBase::getTempDirURL(aRet);
195#endif
196
197 return aRet;
198}
199
200UpdateCheckConfig::UpdateCheckConfig( const uno::Reference<container::XNameContainer>& xContainer,
201 const uno::Reference<container::XNameContainer>& xAvailableUpdates,
202 const uno::Reference<container::XNameContainer>& xIgnoredUpdates,
203 const ::rtl::Reference< UpdateCheckConfigListener >& rListener ) :
204 m_xContainer( xContainer ),
205 m_xAvailableUpdates( xAvailableUpdates ),
206 m_xIgnoredUpdates( xIgnoredUpdates ),
207 m_rListener( rListener )
208{}
209
211{}
212
215 const uno::Reference<uno::XComponentContext>& xContext,
216 const ::rtl::Reference< UpdateCheckConfigListener >& rListener)
217{
218 uno::Reference< lang::XMultiServiceFactory > xConfigProvider(
219 css::configuration::theDefaultProvider::get( xContext ) );
220
221 beans::PropertyValue aProperty;
222 aProperty.Name = "nodepath";
223 aProperty.Value <<= OUString("org.openoffice.Office.Jobs/Jobs/UpdateCheck/Arguments");
224
225 uno::Sequence< uno::Any > aArgumentList{ uno::Any(aProperty) };
226
227 uno::Reference< container::XNameContainer > xContainer(
228 xConfigProvider->createInstanceWithArguments(
229 "com.sun.star.configuration.ConfigurationUpdateAccess", aArgumentList ),
230 uno::UNO_QUERY_THROW );
231
232 aProperty.Value <<= OUString("/org.openoffice.Office.ExtensionManager/ExtensionUpdateData/IgnoredUpdates");
233 aArgumentList = { uno::Any(aProperty) };
234 uno::Reference< container::XNameContainer > xIgnoredExt( xConfigProvider->createInstanceWithArguments( "com.sun.star.configuration.ConfigurationUpdateAccess", aArgumentList ), uno::UNO_QUERY_THROW );
235
236 aProperty.Value <<= OUString("/org.openoffice.Office.ExtensionManager/ExtensionUpdateData/AvailableUpdates");
237 aArgumentList = { uno::Any(aProperty) };
238 uno::Reference< container::XNameContainer > xUpdateAvail( xConfigProvider->createInstanceWithArguments( "com.sun.star.configuration.ConfigurationUpdateAccess", aArgumentList ), uno::UNO_QUERY_THROW );
239
240 return new UpdateCheckConfig( xContainer, xUpdateAvail, xIgnoredExt, rListener );
241}
242
243bool
245{
246 bool nValue = false;
247 const_cast < UpdateCheckConfig *> (this)->getByName( AUTOCHECK_ENABLED ) >>= nValue;
248 return nValue;
249}
250
251bool
253{
254 bool nValue = false;
255 const_cast < UpdateCheckConfig *> (this)->getByName( AUTODOWNLOAD_ENABLED ) >>= nValue;
256 return nValue;
257}
258
259OUString
261{
262 OUString aValue;
263
264 // getByName is defined as non const in XNameAccess
265 const_cast < UpdateCheckConfig *> (this)->getByName( OLD_VERSION ) >>= aValue;
266
267 return aValue;
268}
269
270sal_Int64
272{
273 sal_Int64 nValue = 0;
274
275 // getByName is defined as non const in XNameAccess
276 const_cast < UpdateCheckConfig *> (this)->getByName( LAST_CHECK ) >>= nValue;
277
278 return nValue;
279}
280
281sal_Int64
283{
284 sal_Int64 nValue = 0;
285
286 // getByName is defined as non const in XNameAccess
287 const_cast < UpdateCheckConfig *> (this)->getByName( CHECK_INTERVAL ) >>= nValue;
288
289 return nValue;
290}
291
292OUString
294{
295 OUString aName = LOCAL_FILE;
296 OUString aRet;
297
298 if( m_xContainer->hasByName(aName) )
299 m_xContainer->getByName(aName) >>= aRet;
300
301 return aRet;
302}
303
304OUString
306{
307 OUString aRet;
308
309 const_cast <UpdateCheckConfig *> (this)->getByName(DOWNLOAD_DESTINATION) >>= aRet;
310
311 return aRet;
312}
313
314void
315UpdateCheckConfig::storeLocalFileName(const OUString& rLocalFileName, sal_Int64 nFileSize)
316{
317 const sal_uInt8 nItems = 2;
318 const OUString aNameList[nItems] = { OUString(LOCAL_FILE), OUString(DOWNLOAD_SIZE) };
319 const uno::Any aValueList[nItems] = { uno::Any(rLocalFileName), uno::Any(nFileSize) };
320
321 for( sal_uInt8 i=0; i < nItems; ++i )
322 {
323 if( m_xContainer->hasByName(aNameList[i]) )
324 m_xContainer->replaceByName(aNameList[i], aValueList[i]);
325 else
326 m_xContainer->insertByName(aNameList[i], aValueList[i]);
327 }
328
330}
331
332void
334{
335 const sal_uInt8 nItems = 2;
336 const OUString aNameList[nItems] = { OUString(LOCAL_FILE), OUString(DOWNLOAD_SIZE) };
337
338 for(const auto & i : aNameList)
339 {
340 if( m_xContainer->hasByName(i) )
341 m_xContainer->removeByName(i);
342 }
343
345}
346
347void
349{
352}
353
354void
356{
357 TimeValue systime;
358 osl_getSystemTime(&systime);
359
360 sal_Int64 lastCheck = systime.Seconds;
361
362 replaceByName(LAST_CHECK, uno::Any(lastCheck));
363}
364
365void
366UpdateCheckConfig::storeUpdateFound( const UpdateInfo& rInfo, const OUString& aCurrentBuild)
367
368{
369 bool autoDownloadEnabled = isAutoDownloadEnabled();
370
372 {
373 uno::Any(rInfo.Version),
374 uno::Any(rInfo.BuildId),
375 uno::Any(rInfo.Description),
376 uno::Any(rInfo.Sources[0].URL),
377 uno::Any(rInfo.Sources[0].IsDirect),
378 uno::Any(getReleaseNote(rInfo, 1, autoDownloadEnabled) ),
379 uno::Any(getReleaseNote(rInfo, 2, autoDownloadEnabled) ),
380 uno::Any(getReleaseNote(rInfo, 3, autoDownloadEnabled) ),
381 uno::Any(getReleaseNote(rInfo, 4, autoDownloadEnabled) ),
382 uno::Any(getReleaseNote(rInfo, 5, autoDownloadEnabled) ),
383 uno::Any(aCurrentBuild)
384 };
385
386 OUString aName;
387 for( sal_uInt32 n=0; n < nUpdateEntryProperties; ++n )
388 {
389 aName = OUString::createFromAscii(aUpdateEntryProperties[n]);
390
391 if( m_xContainer->hasByName(aName) )
392 m_xContainer->replaceByName(aName, aValues[n]);
393 else
394 m_xContainer->insertByName(aName,aValues[n]);
395 }
396
398}
399
400void
402{
403 OUString aName;
404
405 for(const char* aUpdateEntryProperty : aUpdateEntryProperties)
406 {
407 aName = OUString::createFromAscii(aUpdateEntryProperty);
408
409 try {
410 if( m_xContainer->hasByName(aName) )
411 m_xContainer->removeByName(aName);
412 } catch(const lang::WrappedTargetException& ) {
413 // Can not remove value, probably in share layer
414 OSL_ASSERT(false);
415 m_xContainer->replaceByName(aName, uno::Any(OUString()));
416 }
417 }
418
419 /* As we have removed UpdateVersionFound from the shared configuration
420 * existing entries in the user layer do not have a oor operation and
421 * thus are completely ignored (which also means they can not be removed).
422 */
423
425}
426
427uno::Type SAL_CALL
429{
430 return m_xContainer->getElementType();
431}
432
433sal_Bool SAL_CALL
435{
436 return m_xContainer->hasElements();
437}
438
439uno::Any SAL_CALL
440UpdateCheckConfig::getByName( const OUString& aName )
441{
442 uno::Any aValue = m_xContainer->getByName( aName );
443
444 // Provide dynamic default value
446 {
447 OUString aStr;
448 aValue >>= aStr;
449
450 if( aStr.isEmpty() )
451 aValue <<= getDownloadsDirectory();
452 }
453 return aValue;
454}
455
456uno::Sequence< OUString > SAL_CALL
458{
459 return m_xContainer->getElementNames();
460}
461
462sal_Bool SAL_CALL
463UpdateCheckConfig::hasByName( const OUString& aName )
464{
465 return m_xContainer->hasByName( aName );
466}
467
468void SAL_CALL
469UpdateCheckConfig::replaceByName( const OUString& aName, const uno::Any& aElement )
470{
471 return m_xContainer->replaceByName( aName, aElement );
472}
473
474// XChangesBatch
475
476void SAL_CALL
478{
479 uno::Reference< util::XChangesBatch > xChangesBatch(m_xContainer, uno::UNO_QUERY);
480 if( xChangesBatch.is() && xChangesBatch->hasPendingChanges() )
481 {
482 util::ChangesSet aChangesSet = xChangesBatch->getPendingChanges();
483 xChangesBatch->commitChanges();
484
485 if( m_rListener.is() )
486 {
487 const sal_Int32 nChanges = aChangesSet.getLength();
488 OUString aString;
489
490 for( sal_Int32 i=0; i<nChanges; ++i )
491 {
492 aChangesSet[i].Accessor >>= aString;
493 if( aString.endsWith(AUTOCHECK_ENABLED "']") )
494 {
495 bool bEnabled = false;
496 aChangesSet[i].Element >>= bEnabled;
497 m_rListener->autoCheckStatusChanged(bEnabled);
498 }
499 else if( aString.endsWith(CHECK_INTERVAL "']") )
500 {
501 m_rListener->autoCheckIntervalChanged();
502 }
503 }
504 }
505 }
506
507 xChangesBatch.set( m_xAvailableUpdates, uno::UNO_QUERY );
508 if( xChangesBatch.is() && xChangesBatch->hasPendingChanges() )
509 {
510 xChangesBatch->commitChanges();
511 }
512 xChangesBatch.set( m_xIgnoredUpdates, uno::UNO_QUERY );
513 if( xChangesBatch.is() && xChangesBatch->hasPendingChanges() )
514 {
515 xChangesBatch->commitChanges();
516 }
517}
518
519sal_Bool SAL_CALL
521{
522 uno::Reference< util::XChangesBatch > xChangesBatch(m_xContainer, uno::UNO_QUERY);
523 if( xChangesBatch.is() )
524 return xChangesBatch->hasPendingChanges();
525
526 return false;
527}
528
529uno::Sequence< util::ElementChange > SAL_CALL
531{
532 uno::Reference< util::XChangesBatch > xChangesBatch(m_xContainer, uno::UNO_QUERY);
533 if( xChangesBatch.is() )
534 return xChangesBatch->getPendingChanges();
535
536 return uno::Sequence< util::ElementChange >();
537}
538
539bool UpdateCheckConfig::storeExtensionVersion( const OUString& rExtensionName,
540 const OUString& rVersion )
541{
542 bool bNotify = true;
543
544 if ( m_xAvailableUpdates->hasByName( rExtensionName ) )
545 uno::Reference< beans::XPropertySet >( m_xAvailableUpdates->getByName( rExtensionName ), uno::UNO_QUERY_THROW )->setPropertyValue( PROPERTY_VERSION, uno::Any( rVersion ) );
546 else
547 {
548 uno::Reference< beans::XPropertySet > elem( uno::Reference< lang::XSingleServiceFactory >( m_xAvailableUpdates, uno::UNO_QUERY_THROW )->createInstance(), uno::UNO_QUERY_THROW );
549 elem->setPropertyValue( PROPERTY_VERSION, uno::Any( rVersion ) );
550 m_xAvailableUpdates->insertByName( rExtensionName, uno::Any( elem ) );
551 }
552
553 if ( m_xIgnoredUpdates->hasByName( rExtensionName ) )
554 {
555 OUString aIgnoredVersion;
556 uno::Any aValue( uno::Reference< beans::XPropertySet >( m_xIgnoredUpdates->getByName( rExtensionName ), uno::UNO_QUERY_THROW )->getPropertyValue( PROPERTY_VERSION ) );
557 aValue >>= aIgnoredVersion;
558 if ( aIgnoredVersion.isEmpty() ) // no version means ignore all updates
559 bNotify = false;
560 else if ( aIgnoredVersion == rVersion ) // the user wanted to ignore this update
561 bNotify = false;
562 }
563
565
566 return bNotify;
567}
568
569bool UpdateCheckConfig::checkExtensionVersion( const OUString& rExtensionName,
570 const OUString& rVersion )
571{
572 if ( m_xAvailableUpdates->hasByName( rExtensionName ) )
573 {
574 OUString aStoredVersion;
575 uno::Any aValue( uno::Reference< beans::XPropertySet >( m_xAvailableUpdates->getByName( rExtensionName ), uno::UNO_QUERY_THROW )->getPropertyValue( PROPERTY_VERSION ) );
576 aValue >>= aStoredVersion;
577
578 if ( m_xIgnoredUpdates->hasByName( rExtensionName ) )
579 {
580 OUString aIgnoredVersion;
581 uno::Any aValue2( uno::Reference< beans::XPropertySet >( m_xIgnoredUpdates->getByName( rExtensionName ), uno::UNO_QUERY_THROW )->getPropertyValue( PROPERTY_VERSION ) );
582 aValue2 >>= aIgnoredVersion;
583 if ( aIgnoredVersion.isEmpty() ) // no version means ignore all updates
584 return false;
585 else if ( aIgnoredVersion == aStoredVersion ) // the user wanted to ignore this update
586 return false;
587 // TODO: else delete ignored entry?
588 }
589 if ( isVersionGreater( rVersion, aStoredVersion ) )
590 return true;
591 else
592 {
593 m_xAvailableUpdates->removeByName( rExtensionName );
595 }
596 }
597
598 return false;
599}
600
601OUString UpdateCheckConfig::getSubVersion( const OUString& rVersion,
602 sal_Int32 *nIndex )
603{
604 while ( *nIndex < rVersion.getLength() && rVersion[*nIndex] == '0')
605 {
606 ++*nIndex;
607 }
608
609 return rVersion.getToken( 0, '.', *nIndex );
610}
611
613bool UpdateCheckConfig::isVersionGreater( const OUString& rVersion1,
614 const OUString& rVersion2 )
615{
616 for ( sal_Int32 i1 = 0, i2 = 0; i1 >= 0 || i2 >= 0; )
617 {
618 OUString sSub1( getSubVersion( rVersion1, &i1 ) );
619 OUString sSub2( getSubVersion( rVersion2, &i2 ) );
620
621 if ( sSub1.getLength() < sSub2.getLength() ) {
622 return true;
623 } else if ( sSub1.getLength() > sSub2.getLength() ) {
624 return false;
625 } else if ( sSub1 < sSub2 ) {
626 return true;
627 } else if ( sSub1 > sSub2 ) {
628 return false;
629 }
630 }
631 return false;
632}
633
634OUString SAL_CALL
636{
637 return "vnd.sun.UpdateCheckConfig";
638}
639
640sal_Bool SAL_CALL
641UpdateCheckConfig::supportsService(OUString const & serviceName)
642{
643 return cppu::supportsService(this, serviceName);
644}
645
646uno::Sequence< OUString > SAL_CALL
648{
649 return { "com.sun.star.setup.UpdateCheckConfig" };
650}
651
652extern "C" SAL_DLLPUBLIC_EXPORT css::uno::XInterface*
654 css::uno::XComponentContext* context , css::uno::Sequence<css::uno::Any> const&)
655{
656 return cppu::acquire(UpdateCheckConfig::get(context, *UpdateCheck::get()).get());
657}
658
659
660/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
bool paused
const char * pName
HRESULT createInstance(REFIID iid, Ifc **ppIfc)
const css::uno::Sequence< css::beans::NamedValue > & m_rValues
css::uno::Any getValue(const char *pName)
const css::uno::Reference< css::container::XNameContainer > m_xIgnoredUpdates
virtual ~UpdateCheckConfig() override
void storeDownloadPaused(bool paused)
sal_Int64 getLastChecked() const
void storeLocalFileName(const OUString &rFileName, sal_Int64 nFileSize)
sal_Int64 getCheckInterval() const
virtual sal_Bool SAL_CALL hasByName(const OUString &aName) override
virtual css::uno::Any SAL_CALL getByName(const OUString &aName) override
static OUString getSubVersion(const OUString &rVersion, sal_Int32 *nIndex)
virtual sal_Bool SAL_CALL hasElements() override
static OUString getAllUsersDirectory()
static OUString getDownloadsDirectory()
bool storeExtensionVersion(const OUString &rExtensionName, const OUString &rVersion)
static bool isVersionGreater(const OUString &rVersion1, const OUString &rVersion2)
checks if the second version string is greater than the first one
OUString getUpdateEntryVersion() const
static ::rtl::Reference< UpdateCheckConfig > get(const css::uno::Reference< css::uno::XComponentContext > &xContext, const ::rtl::Reference< UpdateCheckConfigListener > &rListener=::rtl::Reference< UpdateCheckConfigListener >())
virtual void SAL_CALL replaceByName(const OUString &aName, const css::uno::Any &aElement) override
virtual css::uno::Sequence< OUString > SAL_CALL getElementNames() override
virtual css::uno::Sequence< css::util::ElementChange > SAL_CALL getPendingChanges() override
UpdateCheckConfig(const css::uno::Reference< css::container::XNameContainer > &xContainer, const css::uno::Reference< css::container::XNameContainer > &xAvailableUpdates, const css::uno::Reference< css::container::XNameContainer > &xIgnoredUpdates, const ::rtl::Reference< UpdateCheckConfigListener > &rListener)
virtual sal_Bool SAL_CALL supportsService(OUString const &serviceName) override
bool isAutoCheckEnabled() const
OUString getLocalFileName() const
OUString getDownloadDestination() const
virtual OUString SAL_CALL getImplementationName() override
const ::rtl::Reference< UpdateCheckConfigListener > m_rListener
virtual sal_Bool SAL_CALL hasPendingChanges() override
virtual css::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames() override
bool isAutoDownloadEnabled() const
virtual void SAL_CALL commitChanges() override
bool checkExtensionVersion(const OUString &rExtensionName, const OUString &rVersion)
void storeUpdateFound(const UpdateInfo &rInfo, const OUString &aCurrentBuild)
const css::uno::Reference< css::container::XNameContainer > m_xContainer
const css::uno::Reference< css::container::XNameContainer > m_xAvailableUpdates
virtual css::uno::Type SAL_CALL getElementType() override
OUString getStringValue(const char *) const
void getUpdateEntry(UpdateInfo &rInfo) const
OUString getUpdateEntryVersion() const
sal_Int64 getDownloadSize() const
OUString getLocalFileName() const
bool isDownloadPaused() const
bool isAutoCheckEnabled() const
NamedValueByNameAccess & m_aNameAccess
sal_Int16 nValue
#define TRUE
#define MAX_PATH
sal_Int32 nIndex
OUString aName
sal_Int64 n
#define SAL_N_ELEMENTS(arr)
aStr
bool CPPUHELPER_DLLPUBLIC supportsService(css::lang::XServiceInfo *implementation, rtl::OUString const &name)
int i
css::uno::Reference< css::linguistic2::XProofreadingIterator > get(css::uno::Reference< css::uno::XComponentContext > const &context)
Reference< XNameAccess > m_xContainer
std::vector< DownloadSource > Sources
Definition: updateinfo.hxx:54
OUString BuildId
Definition: updateinfo.hxx:51
OUString Version
Definition: updateinfo.hxx:52
std::vector< ReleaseNote > ReleaseNotes
Definition: updateinfo.hxx:55
OUString Description
Definition: updateinfo.hxx:53
OUString Name
unsigned char sal_uInt8
unsigned char sal_Bool
signed char sal_Int8
OUString getReleaseNote(const UpdateInfo &rInfo, sal_uInt8 pos, bool autoDownloadEnabled)
Definition: updatecheck.cxx:71
#define DOWNLOAD_DESTINATION
#define LOCAL_FILE
#define DOWNLOAD_PAUSED
#define AUTOCHECK_ENABLED
#define IS_DIRECT_DOWNLOAD
#define UPDATE_DESCRIPTION
#define AUTODOWNLOAD_ENABLED
SAL_DLLPUBLIC_EXPORT css::uno::XInterface * extensions_update_UpdateCheckConfig_get_implementation(css::uno::XComponentContext *context, css::uno::Sequence< css::uno::Any > const &)
#define OLD_VERSION
#define UPDATE_VERSION
#define LAST_CHECK
#define RELEASE_NOTE
#define DOWNLOAD_URL
#define CHECK_INTERVAL
#define PROPERTY_VERSION
#define UPDATE_BUILDID
const sal_uInt32 nUpdateEntryProperties
const char *const aUpdateEntryProperties[]
#define DOWNLOAD_SIZE