CalendarWeb Class |
Data contract Rental calendar and possible arrival/departure dates.
The primary goal of an arrival and departure calendar is to correctly identify on which days what vacation types (booking lengths) are available.
RentalObjectCalendarWeb.ArrivalDays and RentalObjectCalendarWeb.DepartureDays contains possible arrival and departure days for the following vacation types:
The calendar also contains the following vacancy details
To correctly parse the calendar the following steps should be taken: Start by identifying an arrival day of interest on the arrival calendar. To do this, use the offset date on the calendar and calculate how many groups (days) to skip to find the group of interest. Once found, the contents of the arrival day group can be used to calculate allowed arrival days. The goal is to find out what lengths between 2 and 28 days are possible for this specific arrival day.
Here are the possible values to help determine an allowed departure day:
*When checking if a character is either on the arrival or departure calendar, start by looping the arrival calendar and check for that character. If a day is reached where the characters is no longer there, then continue from that day on the departure calendar, and continue checking for that character until the desired departure date is reached.
Please note
Please be aware that the calendar string format described above is obsolete and is only available to avoid breaking the contract with old client proxies.
Please use the new duration based format in stead. The description of this duration based format can be found in the comments to the field ArrivalDays
If the field IncludeCalendarDurations is set to true, a CalendarWeb instance containing the duration based format, will be
returned in the field CalendarDurations. The field Calendar always contains the old obsolete format.
Namespace: Tse.EasyBook.Server.DataContracts
public class CalendarWeb : DataContractBase
The CalendarWeb type exposes the following members.
Name | Description | |
---|---|---|
![]() | CalendarWeb |
Name | Description | |
---|---|---|
![]() | ArrivalDays |
If the field DurationFormat either is absent or contains the value false, then this field contains a string formatted
as described in the comments on the class for this field. Otherwise this field contains a string containing the new duration based calender string format. For the duration based format each day has one of the following 4 values:
Value 2 represent a vacant day that is available for booking, but where arrival is NOT possible. Value 3 and 4 represent a occupied day that is NOT available for booking. All the days between the date Offset and the date of EndDate, both included, are represented by one of the 4 values followed by a comma. Example of a string value for ArrivalDays: A12384,a,a,a,a,a,a,A96,a,a,a,a,a,a,b,b |
![]() | DepartureDays |
If the field DurationFormat either is absent or contains the value false, then this field contains a string formatted
as described in comments to the class CalendarWeb.
Otherwise this field is empty.
|
![]() | DurationFormat |
If true the field ArrivalDays contains a duration calendar string format and the field DepartureDays is null.
Otherwise these fields contains the normal calendar string format.
|
![]() | EndDate |
Property StartDateOfDays
|
![]() | Offset |
Property StartDateOfDays
|
Name | Description | |
---|---|---|
![]() ![]() | GetVacancyTypesDescription |
Get description of possible vacancy type codes
|