Dates, Times, Durations

Jason Rogers jacaetevha at fast-mail.org
Thu Jan 20 20:21:05 UTC 2005


On Thursday 20 January 2005 15:03, Michael Latta wrote:
> If you wanted to be more general (not count weekends, holidays, etc.) I
> would create a Schedule class that knows when work is happening.  This
> schedule would then do the computation of work hours in a period.
>
> Rather than testing each hour of the period, break the time into 3
> portions.  Hours that begin the period that are a partial work day,
> those that are full work days, and those that end the period in a work
> day.  Do the below for the first and last parts of the period, and do
> something more efficient for the full work days.

Great thanks!

-- 
Jason Rogers

"I am crucified with Christ: nevertheless I live; yet not I,
but Christ liveth in me: and the life which I now live in 
the flesh I live by the faith of the Son of God, who loved 
me, and gave himself for me."
    Galatians 2:20



More information about the Squeak-dev mailing list