LibreOffice Module basctl (master) 1
sbxitem.hxx
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#pragma once
20
21#include "scriptdocument.hxx"
22#include <svl/poolitem.hxx>
23
24namespace basctl
25{
26
28{
35};
36
37class SbxItem : public SfxPoolItem
38{
40 const OUString m_aLibName;
41 const OUString m_aName;
42 const OUString m_aMethodName;
44
45public:
46 static SfxPoolItem* CreateDefault();
47 SbxItem(sal_uInt16 nWhich, ScriptDocument aDocument, OUString aLibName, OUString aName, ItemType);
48 SbxItem(sal_uInt16 nWhich, ScriptDocument aDocument, OUString aLibName, OUString aName, OUString aMethodName, ItemType eType);
49
50 virtual SbxItem* Clone(SfxItemPool *pPool = nullptr) const override;
51 virtual bool operator==(const SfxPoolItem&) const override;
52
53 ScriptDocument const& GetDocument () const { return m_aDocument; }
54 OUString const& GetLibName () const { return m_aLibName; }
55 OUString const& GetName () const { return m_aName; }
56 OUString const& GetMethodName () const { return m_aMethodName; }
57 ItemType GetType () const { return m_eType; }
58};
59
60} // namespace basctl
61
62// For baside.sdi, because I don't know how to use nested names in it.
63using basctl::SbxItem;
64
65/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
ScriptDocument aDocument
Definition: basobj2.cxx:194
ScriptDocument const & GetDocument() const
Definition: sbxitem.hxx:53
OUString const & GetMethodName() const
Definition: sbxitem.hxx:56
ItemType GetType() const
Definition: sbxitem.hxx:57
SbxItem(sal_uInt16 nWhich, ScriptDocument aDocument, OUString aLibName, OUString aName, ItemType)
Definition: sbxitem.cxx:27
ItemType m_eType
Definition: sbxitem.hxx:43
const OUString m_aLibName
Definition: sbxitem.hxx:40
OUString const & GetLibName() const
Definition: sbxitem.hxx:54
const OUString m_aName
Definition: sbxitem.hxx:41
OUString const & GetName() const
Definition: sbxitem.hxx:55
virtual SbxItem * Clone(SfxItemPool *pPool=nullptr) const override
Definition: sbxitem.cxx:57
const ScriptDocument m_aDocument
Definition: sbxitem.hxx:39
const OUString m_aMethodName
Definition: sbxitem.hxx:42
virtual bool operator==(const SfxPoolItem &) const override
Definition: sbxitem.cxx:62
static SfxPoolItem * CreateDefault()
Definition: sbxitem.cxx:26
encapsulates a document which contains Basic scripts and dialogs
ItemType
Definition: sbxitem.hxx:28
@ TYPE_MODULE
Definition: sbxitem.hxx:32
@ TYPE_METHOD
Definition: sbxitem.hxx:34
@ TYPE_LIBRARY
Definition: sbxitem.hxx:31
@ TYPE_UNKNOWN
Definition: sbxitem.hxx:29
@ TYPE_SHELL
Definition: sbxitem.hxx:30
@ TYPE_DIALOG
Definition: sbxitem.hxx:33