LibreOffice Module sc (master) 1
|
Represents a collection of hyperlinks of a worksheet or of a range. More...
#include <vbahyperlinks.hxx>
Public Member Functions | |
ScVbaHyperlinks (const css::uno::Reference< ov::XHelperInterface > &rxParent, const css::uno::Reference< css::uno::XComponentContext > &rxContext) | |
ScVbaHyperlinks (const css::uno::Reference< ov::XHelperInterface > &rxParent, const css::uno::Reference< css::uno::XComponentContext > &rxContext, const ScVbaHyperlinksRef &rxSheetHlinks, const ScRangeList &rScRanges) | |
virtual | ~ScVbaHyperlinks () override |
virtual css::uno::Reference< ov::excel::XHyperlink > SAL_CALL | Add (const css::uno::Any &rAnchor, const css::uno::Any &rAddress, const css::uno::Any &rSubAddress, const css::uno::Any &rScreenTip, const css::uno::Any &rTextToDisplay) override |
virtual void SAL_CALL | Delete () override |
virtual css::uno::Reference< css::container::XEnumeration > SAL_CALL | createEnumeration () override |
virtual css::uno::Type SAL_CALL | getElementType () override |
virtual css::uno::Any | createCollectionObject (const css::uno::Any &rSource) override |
![]() | |
CollTestImplHelper (const css::uno::Reference< ov::XHelperInterface > &xParent, const css::uno::Reference< css::uno::XComponentContext > &xContext, const css::uno::Reference< css::container::XIndexAccess > &xIndexAccess, bool bIgnoreCase=false) | |
![]() | |
ScVbaCollectionBase (const css::uno::Reference< ov::XHelperInterface > &xParent, const css::uno::Reference< css::uno::XComponentContext > &xContext, css::uno::Reference< css::container::XIndexAccess > xIndexAccess, bool bIgnoreCase=false) | |
virtual ::sal_Int32 SAL_CALL | getCount () override |
virtual css::uno::Any SAL_CALL | Item (const css::uno::Any &Index1, const css::uno::Any &) override |
OUString SAL_CALL | getDefaultMethodName () override |
virtual css::uno::Reference< css::container::XEnumeration > SAL_CALL | createEnumeration () override=0 |
virtual css::uno::Type SAL_CALL | getElementType () override=0 |
virtual sal_Bool SAL_CALL | hasElements () override |
virtual css::uno::Any | createCollectionObject (const css::uno::Any &aSource)=0 |
![]() | |
InheritedHelperInterfaceImpl (const css::uno::Reference< ov::XHelperInterface > &xParent, css::uno::Reference< css::uno::XComponentContext > xContext) | |
virtual OUString | getServiceImplName ()=0 |
virtual css::uno::Sequence< OUString > | getServiceNames ()=0 |
virtual ::sal_Int32 SAL_CALL | getCreator () override |
virtual css::uno::Reference< ov::XHelperInterface > SAL_CALL | getParent () override |
virtual css::uno::Any SAL_CALL | Application () override |
virtual OUString SAL_CALL | getImplementationName () override |
virtual sal_Bool SAL_CALL | supportsService (const OUString &ServiceName) override |
virtual css::uno::Sequence< OUString > SAL_CALL | getSupportedServiceNames () override |
Private Attributes | |
ScVbaHyperlinksRef | mxSheetHlinks |
![]() | |
ScVbaHlinkContainerRef | mxContainer |
Additional Inherited Members | |
![]() | |
virtual css::uno::Any | getItemByStringIndex (const OUString &sIndex) |
virtual css::uno::Any | getItemByIntIndex (const sal_Int32 nIndex) |
void | UpdateCollectionIndex (const css::uno::Reference< css::container::XIndexAccess > &xIndexAccess) |
![]() | |
css::uno::Reference< css::container::XIndexAccess > | m_xIndexAccess |
css::uno::Reference< css::container::XNameAccess > | m_xNameAccess |
bool | mbIgnoreCase |
![]() | |
css::uno::WeakReference< ov::XHelperInterface > | mxParent |
css::uno::Reference< css::uno::XComponentContext > | mxContext |
![]() | |
ScVbaHlinkContainerMember (ScVbaHlinkContainer *pContainer) | |
~ScVbaHlinkContainerMember () | |
Represents a collection of hyperlinks of a worksheet or of a range.
When a Hyperlinks collection object has been constructed from a VBA Worksheet object, it will always represent the current set of all hyperlinks existing in the sheet. Insertion and deletion of hyperlinks will be reflected by the instance.
When a Hyperlinks collection object has been constructed from a VBA Range object, it will represent the set of hyperlinks that have existed at its construction time, and that are located completely inside the range(s) represented by the Range object. Insertion and deletion of hyperlinks will not* be reflected by that instance. The instance will always offer all hyperlinks it has been constructed with, even if they no longer exist. Furthermore, the instance will not offer hyperlinks inserted later, even if the instance itself has been used to insert the new hyperlinks.
VBA code example:
With ThisWorkbook.Worksheets(1)
Set hlinks = .Hyperlinks ' global Hyperlinks object Set myrange = .Range("A1:C3") Set rangelinks1 = myrange.Hyperlinks ' hyperlinks of range A1:C3 MsgBox hlinks.Count ' 0 MsgBox rangelinks1.Count ' 0 hlinks.Add .Range("A1"), "http://example.com" ' a new hyperlink has been added in cell A1 MsgBox hlinks.Count ' 1 MsgBox rangelinks1.Count ' still 0! Set rangelinks2 = myrange.Hyperlinks ' hyperlinks of range A1:C3 MsgBox rangelinks2.Count ' 1 (constructed after Add) rangelinks1.Add .Range("A2"), "http://example.com" ' a new hyperlink has been constructed via the rangelinks1 object ' but this addition has been done by the worksheet Hyperlinks object MsgBox hlinks.Count ' 2 MsgBox rangelinks1.Count ' still 0!!! MsgBox rangelinks2.Count ' still 1!!! MsgBox myrange.Hyperlinks.Count ' 2 (constructed after Add)
End With
Definition at line 97 of file vbahyperlinks.hxx.
|
explicit |
css::uno::RuntimeException |
|
explicit |
css::uno::RuntimeException |
References VBAHELPER_DECL_XHELPERINTERFACE.
|
overridevirtual |
Definition at line 212 of file vbahyperlinks.cxx.
|
overridevirtual |
Definition at line 218 of file vbahyperlinks.cxx.
References mxContainer, and mxContext.
|
overridevirtual |
Implements ScVbaCollectionBase< ::cppu::WeakImplHelper< Ifc... > >.
Definition at line 267 of file vbahyperlinks.cxx.
|
overridevirtual |
Implements ScVbaCollectionBase< ::cppu::WeakImplHelper< Ifc... > >.
Definition at line 253 of file vbahyperlinks.cxx.
|
overridevirtual |
Definition at line 245 of file vbahyperlinks.cxx.
|
overridevirtual |
Implements ScVbaCollectionBase< ::cppu::WeakImplHelper< Ifc... > >.
Definition at line 260 of file vbahyperlinks.cxx.
References cppu::UnoType< typename T >::get().
|
private |
Definition at line 133 of file vbahyperlinks.hxx.