Avoid potential negative array index access to cached text.
[LibreOffice.git] / vcl / inc / graphic / UnoBinaryDataContainer.hxx
blobf4a63ce60dc6271a069371fb008e56c51fb336c3
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3 * This file is part of the LibreOffice project.
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/.
9 * This file incorporates work covered by the following license notice:
13 #pragma once
15 #include <cppuhelper/implbase.hxx>
17 #include <com/sun/star/util/XBinaryDataContainer.hpp>
19 #include <utility>
20 #include <vcl/BinaryDataContainer.hxx>
22 class UnoBinaryDataContainer final : public cppu::WeakImplHelper<css::util::XBinaryDataContainer>
24 private:
25 BinaryDataContainer maBinaryDataContainer;
27 public:
28 UnoBinaryDataContainer(BinaryDataContainer aBinaryDataContainer)
29 : maBinaryDataContainer(std::move(aBinaryDataContainer))
33 BinaryDataContainer const& getBinaryDataContainer() const { return maBinaryDataContainer; }
35 // XBinaryDataContainer
36 css::uno::Sequence<sal_Int8> SAL_CALL getCopyAsByteSequence() override;
39 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */