

Predefined Content Guide › Business Logic Modules › Library Modules › Business Day Counting Library
Business Day Counting Library
This module does the actual calculation of timestamps to figure out when a business day starts and ends. Two different logics are supplied:
- Within X days – This takes the opening time of a ticket into account when counting days. For example, if the ticket is opened at 14:00 and closed at 13:00 the next business day, this is counted as a single day. If the ticket were to close at 15:00 on the next business day, that would count as two days.
- Same day, Next day – This ignores ticket open time. Any second in the day that has an active timeslot (and is thus considered a business day) makes that day count as a whole day. For example, a ticket that was opened on the last second of the timeslot of day 1 makes that day count as a whole day. When a ticket opened after the timeslot of day 1, that day is not counted. If the ticket is marked same day, the ticket must close before the end of that day. Note that which day is determined by the first ‘within timeslot’ second after the ticket is opened. A ticket that is opened after today’s timeslot exit is only considered as active the next day, so a same day ticket would have to be closed tomorrow end of day, if it was opened after today’s timeslot exit A ticket that is closed after midnight of the opening day is counted as two days.
Both business days logics are based on the same modules and differ only in their parameter settings.
- Single timeslot – This functionality is based the single timeslot/time-zone of the calculating metric itself. You need to implement the following parameters:
- Multiple timeslots – In addition to the explanation above about single timeslot functionality, the new functionality supports multiple timeslot events. This support comes through an additional extension library called Within X Business Days By Timeslots Extension Library. This library is connected to the metric itself. It adds the timeslots functionality and requires an extra pair of parameters:
- RegistrationList –A table parameter with a single field called LocationId. This table is filled with the list of location timeslot events sending metrics that have to be located in the same contract.
- EventLocationId – The definition of what the system needs to do to determine an incoming event’s location.
Also, to enable this functionality, a new event type was added, to allow for the handling of daylight savings time changes across ticket lifecycles.
This event type is called LocationDstChangeNotification and has the following specifications:
- LocationId as string.
- DistanceFromUtc as integer.
Module Dependencies
The following table lists the included modules.
|
Name
|
Description
|
|
Log Library (LL)
|
Library for enhanced logging functionality.
|
|
Parameters Kernel Library (PKL)
|
Library responsible for verifying and populating module parameters.
|
Copyright © 2012 CA.
All rights reserved.
 
|
|