LibreOffice Module scaddins (master) 1
Public Member Functions | Private Member Functions | Private Attributes | List of all members
sca::analysis::SortedIndividualInt32List Class Referencefinal

sorted list with unique sal_Int32 values More...

#include <analysishelper.hxx>

Public Member Functions

 SortedIndividualInt32List ()
 
 ~SortedIndividualInt32List ()
 
sal_uInt32 Count () const
 
sal_Int32 Get (sal_uInt32 n) const
 
bool Find (sal_Int32 nVal) const
 
void InsertHolidayList (ScaAnyConverter &rAnyConv, const css::uno::Reference< css::beans::XPropertySet > &xOptions, const css::uno::Any &rHolAny, sal_Int32 nNullDate)
 

Private Member Functions

void Insert (sal_Int32 nDay)
 
void Insert (sal_Int32 nDay, sal_Int32 nNullDate, bool bInsertOnWeekend)
 
void Insert (double fDay, sal_Int32 nNullDate, bool bInsertOnWeekend)
 
void InsertHolidayList (const ScaAnyConverter &rAnyConv, const css::uno::Any &rHolAny, sal_Int32 nNullDate, bool bInsertOnWeekend)
 

Private Attributes

std::vector< sal_Int32 > maVector
 

Detailed Description

sorted list with unique sal_Int32 values

Definition at line 243 of file analysishelper.hxx.

Constructor & Destructor Documentation

◆ SortedIndividualInt32List()

sca::analysis::SortedIndividualInt32List::SortedIndividualInt32List ( )

Definition at line 1374 of file analysishelper.cxx.

◆ ~SortedIndividualInt32List()

sca::analysis::SortedIndividualInt32List::~SortedIndividualInt32List ( )

Definition at line 1379 of file analysishelper.cxx.

Member Function Documentation

◆ Count()

sal_uInt32 sca::analysis::SortedIndividualInt32List::Count ( ) const
inline

Definition at line 269 of file analysishelper.hxx.

References maVector.

Referenced by Find(), and Insert().

◆ Find()

bool sca::analysis::SortedIndividualInt32List::Find ( sal_Int32  nVal) const
Returns
true if nVal (internal date representation) is contained

Definition at line 1423 of file analysishelper.cxx.

References Count(), Get(), n, and nRef.

Referenced by AnalysisAddIn::getNetworkdays(), and AnalysisAddIn::getWorkday().

◆ Get()

sal_Int32 sca::analysis::SortedIndividualInt32List::Get ( sal_uInt32  n) const
inline
Returns
element on position nIndex or 0 on invalid index

Definition at line 273 of file analysishelper.hxx.

References maVector, and n.

Referenced by Find(), and Insert().

◆ Insert() [1/3]

void sca::analysis::SortedIndividualInt32List::Insert ( double  fDay,
sal_Int32  nNullDate,
bool  bInsertOnWeekend 
)
private
Exceptions
css::uno::RuntimeException
css::lang::IllegalArgumentException

Definition at line 1414 of file analysishelper.cxx.

References Insert().

◆ Insert() [2/3]

void sca::analysis::SortedIndividualInt32List::Insert ( sal_Int32  nDay)
private

Definition at line 1384 of file analysishelper.cxx.

References Count(), Get(), maVector, nIndex, and nRef.

Referenced by Insert().

◆ Insert() [3/3]

void sca::analysis::SortedIndividualInt32List::Insert ( sal_Int32  nDay,
sal_Int32  nNullDate,
bool  bInsertOnWeekend 
)
private

Definition at line 1403 of file analysishelper.cxx.

References sca::analysis::GetDayOfWeek(), and Insert().

◆ InsertHolidayList() [1/2]

void sca::analysis::SortedIndividualInt32List::InsertHolidayList ( const ScaAnyConverter rAnyConv,
const css::uno::Any &  rHolAny,
sal_Int32  nNullDate,
bool  bInsertOnWeekend 
)
private
Parameters
rAnyConvmust be an initialized ScaAnyConmverter
bInsertOnWeekendinsertion mode: false = holidays on weekend are omitted
Exceptions
css::uno::RuntimeException
css::lang::IllegalArgumentException

Referenced by AnalysisAddIn::getNetworkdays(), and AnalysisAddIn::getWorkday().

◆ InsertHolidayList() [2/2]

void sca::analysis::SortedIndividualInt32List::InsertHolidayList ( ScaAnyConverter rAnyConv,
const css::uno::Reference< css::beans::XPropertySet > &  xOptions,
const css::uno::Any &  rHolAny,
sal_Int32  nNullDate 
)
Parameters
rAnyConvis an initialized or uninitialized ScaAnyConverter holidays on weekend are omitted
Exceptions
css::uno::RuntimeException
css::lang::IllegalArgumentException

Member Data Documentation

◆ maVector

std::vector<sal_Int32> sca::analysis::SortedIndividualInt32List::maVector
private

Definition at line 246 of file analysishelper.hxx.

Referenced by Count(), Get(), and Insert().


The documentation for this class was generated from the following files: