Skip to content
This repository has been archived by the owner on May 8, 2024. It is now read-only.

Latest commit

 

History

History
32 lines (20 loc) · 1.24 KB

getEvents.md

File metadata and controls

32 lines (20 loc) · 1.24 KB

Function getEvents

The getEvents function allows you to retrieve a list of events for a specific day. This function takes a dayIndex parameter to specify the day for which you want to retrieve the events.

Method Signature

getEvents(dayIndex: int) (list<pure Event>)

Parameters

  • dayIndex (type: int): Specifies the index of the day. It represents the position of the day in the day range ZODIAC was invoked with, starting from 0 for the first day.

Return Value

The getEvents function returns a list of Event objects representing the events for the specified day.

Example Usage

var events: list<pure Event> = getEvents(2);

In this example, the getEvents function is called with dayIndex 2 to retrieve the events for the third day. The events are stored in the events variable as a list of Event objects.

Notes

  • The dayIndex parameter should be a valid index within the range of available days.
  • The events contained in the list are immutable and therefore cannot be changed.
  • The returned list of Event objects can be empty if there are no events for the specified day.
  • The Event objects can contain various properties such as event title, description, start time, end time, etc.