Impress Remote 1.0.5, tag sdremote-1.0.5
[LibreOffice.git] / sc / inc / dputil.hxx
blob4ed4e5c679eacdf0f99070e0a50a864f20905046
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3 * Version: MPL 1.1 / GPLv3+ / LGPLv3+
5 * The contents of this file are subject to the Mozilla Public License Version
6 * 1.1 (the "License"); you may not use this file except in compliance with
7 * the License or as specified alternatively below. You may obtain a copy of
8 * the License at http://www.mozilla.org/MPL/
10 * Software distributed under the License is distributed on an "AS IS" basis,
11 * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
12 * for the specific language governing rights and limitations under the
13 * License.
15 * Major Contributor(s):
16 * Copyright (C) 2012 Kohei Yoshida <kohei.yoshida@suse.com>
18 * All Rights Reserved.
20 * For minor contributions see the git repository.
22 * Alternatively, the contents of this file may be used under the terms of
23 * either the GNU General Public License Version 3 or later (the "GPLv3+"), or
24 * the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
25 * in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
26 * instead of those above.
29 #ifndef __SC_DPUTIL_HXX__
30 #define __SC_DPUTIL_HXX__
32 #include "rtl/ustring.hxx"
33 #include "scdllapi.h"
35 class SvNumberFormatter;
36 struct ScDPNumGroupInfo;
38 class ScDPUtil
40 public:
41 static bool isDuplicateDimension(const rtl::OUString& rName);
43 SC_DLLPUBLIC static rtl::OUString getSourceDimensionName(const rtl::OUString& rName);
45 static rtl::OUString createDuplicateDimensionName(const rtl::OUString& rOriginal, size_t nDupCount);
47 static rtl::OUString getDateGroupName(
48 sal_Int32 nDatePart, sal_Int32 nValue, SvNumberFormatter* pFormatter,
49 double fStart, double fEnd);
51 static double getNumGroupStartValue(double fValue, const ScDPNumGroupInfo& rInfo);
53 static rtl::OUString getNumGroupName(
54 double fValue, const ScDPNumGroupInfo& rInfo, sal_Unicode cDecSep,
55 SvNumberFormatter* pFormatter);
57 static sal_Int32 getDatePartValue(
58 double fValue, const ScDPNumGroupInfo& rInfo, sal_Int32 nDatePart,
59 SvNumberFormatter* pFormatter);
62 #endif
64 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */