Re: Calendar with custom set holidays and name
Posted by
Luigi Ballabio on
URL: http://quantlib.414.s1.nabble.com/Calendar-with-custom-set-holidays-and-name-tp53p56.html
On Mon, 2010-12-20 at 15:20 +0100, Henner Heck wrote:
> [...] it seems to me that BespokeCalendar
> bases it's isBusinessDay() and therefore also
> it's isHoliday() on the weekday of a date alone:
>
> <bespokecalendar.cpp, line 36>
> bool BespokeCalendar::Impl::isBusinessDay(const Date& date) const {
> return !isWeekend(date.weekday());
> }
>
> So e.g. every Monday or every Wednesday would appear as a
> holiday/businessday,
> but not just specific days defined by year;month;day, or am i wrong on
> this?
Right as far as the specific implementation is concerned, but the
Calendar class wraps it with an additional search for the dates you set
with addHoliday, so you'll get those as well.
Luigi
--
Hanlon's Razor:
Never attribute to malice that which is adequately explained
by stupidity.
------------------------------------------------------------------------------
Lotusphere 2011
Register now for Lotusphere 2011 and learn how
to connect the dots, take your collaborative environment
to the next level, and enter the era of Social Business.
http://p.sf.net/sfu/lotusphere-d2d_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users