LibreOffice Module basic (master) 1
Classes | Macros | Typedefs | Functions | Variables
basmgr.cxx File Reference
#include <utility>
#include <vcl/errinf.hxx>
#include <tools/stream.hxx>
#include <sot/storage.hxx>
#include <tools/urlobj.hxx>
#include <svl/hint.hxx>
#include <basic/sbx.hxx>
#include <basic/sbmeth.hxx>
#include <sot/storinfo.hxx>
#include <unotools/pathoptions.hxx>
#include <tools/debug.hxx>
#include <comphelper/diagnose_ex.hxx>
#include <basic/sbmod.hxx>
#include <unotools/transliterationwrapper.hxx>
#include <sal/log.hxx>
#include <o3tl/string_view.hxx>
#include <basic/sberrors.hxx>
#include <basic/sbuno.hxx>
#include <basic/basmgr.hxx>
#include <global.hxx>
#include <com/sun/star/script/XLibraryContainer.hpp>
#include <com/sun/star/script/XPersistentLibraryContainer.hpp>
#include <scriptcont.hxx>
#include <memory>
#include <vector>
#include <com/sun/star/container/XNameContainer.hpp>
#include <com/sun/star/container/XContainer.hpp>
#include <com/sun/star/script/XStarBasicAccess.hpp>
#include <com/sun/star/script/XStarBasicModuleInfo.hpp>
#include <com/sun/star/script/XStarBasicDialogInfo.hpp>
#include <com/sun/star/script/XStarBasicLibraryInfo.hpp>
#include <com/sun/star/script/XLibraryContainerPassword.hpp>
#include <com/sun/star/script/ModuleInfo.hpp>
#include <com/sun/star/script/vba/XVBACompatibility.hpp>
#include <com/sun/star/script/vba/XVBAModuleInfo.hpp>
#include <com/sun/star/ucb/ContentCreationException.hpp>
#include <cppuhelper/implbase.hxx>
Include dependency graph for basmgr.cxx:

Go to the source code of this file.

Classes

class  BasMgrContainerListenerImpl
 
class  BasicLibInfo
 
class  LibraryContainer_Impl
 
class  StarBasicAccess_Impl
 

Macros

#define LIB_SEP   0x01
 
#define LIBINFO_SEP   0x02
 
#define LIBINFO_ID   0x1491
 
#define PASSWORD_MARKER   0x31452134
 
#define SBXID_DIALOG   101
 

Typedefs

typedef WeakImplHelper< container::XNameContainer > NameContainerHelper
 
typedef WeakImplHelper< script::XStarBasicModuleInfo > ModuleInfoHelper
 
typedef WeakImplHelper< script::XStarBasicAccess > StarBasicAccessHelper
 
typedef ::cppu::WeakImplHelper< container::XContainerListener > ContainerListenerHelper
 

Functions

static void copyToLibraryContainer (StarBASIC *pBasic, const LibraryContainerInfo &rInfo)
 
static uno::Sequence< sal_Int8implGetDialogData (SbxObject *pDialog)
 
static SbxObjectRef implCreateDialog (const uno::Sequence< sal_Int8 > &aData)
 
uno::Reference< script::XStarBasicAccess > getStarBasicAccess (BasicManager *pMgr)
 

Variables

constexpr OUStringLiteral szStdLibName = u"Standard"
 
constexpr OUStringLiteral szBasicStorage = u"StarBASIC"
 
constexpr OUStringLiteral szOldManagerStream = u"BasicManager"
 
constexpr OUStringLiteral szManagerStream = u"BasicManager2"
 
constexpr OUStringLiteral szImbedded = u"LIBIMBEDDED"
 
constexpr OStringLiteral szCryptingKey = "CryptedBasic"
 
const StreamMode eStreamReadMode = StreamMode::READ | StreamMode::NOCREATE | StreamMode::SHARE_DENYALL
 
const StreamMode eStorageReadMode = StreamMode::READ | StreamMode::SHARE_DENYWRITE
 

Macro Definition Documentation

◆ LIB_SEP

#define LIB_SEP   0x01

Definition at line 49 of file basmgr.cxx.

◆ LIBINFO_ID

#define LIBINFO_ID   0x1491

Definition at line 51 of file basmgr.cxx.

◆ LIBINFO_SEP

#define LIBINFO_SEP   0x02

Definition at line 50 of file basmgr.cxx.

◆ PASSWORD_MARKER

#define PASSWORD_MARKER   0x31452134

Definition at line 52 of file basmgr.cxx.

◆ SBXID_DIALOG

#define SBXID_DIALOG   101

Definition at line 1776 of file basmgr.cxx.

Typedef Documentation

◆ ContainerListenerHelper

typedef ::cppu::WeakImplHelper< container::XContainerListener > ContainerListenerHelper

Definition at line 105 of file basmgr.cxx.

◆ ModuleInfoHelper

typedef WeakImplHelper< script::XStarBasicModuleInfo > ModuleInfoHelper

Definition at line 77 of file basmgr.cxx.

◆ NameContainerHelper

typedef WeakImplHelper< container::XNameContainer > NameContainerHelper

Definition at line 76 of file basmgr.cxx.

◆ StarBasicAccessHelper

typedef WeakImplHelper< script::XStarBasicAccess > StarBasicAccessHelper

Definition at line 78 of file basmgr.cxx.

Function Documentation

◆ copyToLibraryContainer()

static void copyToLibraryContainer ( StarBASIC pBasic,
const LibraryContainerInfo rInfo 
)
static

◆ getStarBasicAccess()

uno::Reference< script::XStarBasicAccess > getStarBasicAccess ( BasicManager pMgr)

Definition at line 2112 of file basmgr.cxx.

◆ implCreateDialog()

static SbxObjectRef implCreateDialog ( const uno::Sequence< sal_Int8 > &  aData)
static

Definition at line 1766 of file basmgr.cxx.

References aData, tools::SvRef< typename T >::get(), SbxBase::Load(), and pData.

◆ implGetDialogData()

static uno::Sequence< sal_Int8 > implGetDialogData ( SbxObject pDialog)
static

Definition at line 1753 of file basmgr.cxx.

References aData, SvMemoryStream::GetData(), SbxBase::Store(), and SvStream::Tell().

Variable Documentation

◆ eStorageReadMode

Definition at line 100 of file basmgr.cxx.

Referenced by BasicManager::ImpLoadLibrary(), and BasicManager::LoadOldBasicManager().

◆ eStreamReadMode

◆ szBasicStorage

constexpr OUStringLiteral szBasicStorage = u"StarBASIC"
constexpr

Definition at line 92 of file basmgr.cxx.

Referenced by BasicManager::ImpLoadLibrary(), and BasicManager::RemoveLib().

◆ szCryptingKey

constexpr OStringLiteral szCryptingKey = "CryptedBasic"
constexpr

Definition at line 96 of file basmgr.cxx.

Referenced by BasicManager::ImplEncryptStream(), and BasicManager::ImpLoadLibrary().

◆ szImbedded

constexpr OUStringLiteral szImbedded = u"LIBIMBEDDED"
constexpr

◆ szManagerStream

constexpr OUStringLiteral szManagerStream = u"BasicManager2"
constexpr

Definition at line 94 of file basmgr.cxx.

Referenced by BasicManager::BasicManager(), and BasicManager::LoadBasicManager().

◆ szOldManagerStream

constexpr OUStringLiteral szOldManagerStream = u"BasicManager"
constexpr

Definition at line 93 of file basmgr.cxx.

Referenced by BasicManager::BasicManager(), and BasicManager::LoadOldBasicManager().

◆ szStdLibName

constexpr OUStringLiteral szStdLibName = u"Standard"
constexpr