PageRenderTime 5ms CodeModel.GetById 1ms app.highlight 1ms RepoModel.GetById 1ms app.codeStats 0ms

/lib/titanium/mobile/android/calendar/Calendar.hx

http://github.com/visup/haxe-titanium-api
Haxe | 99 lines | 17 code | 4 blank | 78 comment | 0 complexity | 10ece0c4ef5ccacf752458b9f8d81f2a MD5 | raw file
 1package titanium.mobile.android.calendar;
 2
 3
 4/**
 5Calendar class
 6
 7Documentation available at:
 8http://developer.appcelerator.com/apidoc/mobile/latest/Titanium.Android.Calendar.Calendar-object
 9
10- namespace
11
12Titanium.Android.Calendar.Calendar
13
14- type
15
16object
17
18- description
19
20An object which represents a single calendar in Android.
21
22- since
23
241.5
25
26- platforms
27
28android
29
30- properties
31
32name[string]: The display name of the calendar.
33id[string]: The id of the calendar.
34selected[boolean]: Whether the calendar is selected.
35hidden[boolean]: Whether the calendar is hidden.
36
37- methods
38
39createEvent: Add an event to the calendar. Returns the created `Titanium.Android.Calendar.Event`.
40getEventsBetweenDates: Returns an array of `Titanium.Android.Calendar.Event` objects with all events in the given date range.
41getEventById: Returns the `Titanium.Android.Calendar.Event` object for the event with the given integer id.
42getEventsInDate: Returns an array of `Titanium.Android.Calendar.Event` objects with all events on the given date.
43getEventsInMonth: Returns an array of `Titanium.Android.Calendar.Event` objects with all events in the given month.
44getEventsInYear: Returns an array of `Titanium.Android.Calendar.Event` objects with all events in the given year.
45
46- method : createEvent, object
47
48properties[object]: An object defining the properties of the event.  These correspond to properties of `Titanium.Android.Calendar.Event`.
49
50- method : getEventsBetweenDates, array
51
52date1[date]: The start date.
53date2[date]: The end date.
54
55- method : getEventById, object
56
57id[int]: The integer id of the event to return.
58
59- method : getEventsInDate, array
60
61year[int]: The year of the desired date.
62month[int]: The month of the desired date.  The month is zero-based, therefore January is 0 and December is 11.
63day[int]: The day for which events should be returned.
64
65- method : getEventsInMonth, array
66
67year[int]: The year of the desired month.
68month[int]: The month for which events should be returned.  The month is zero-based, therefore January is 0 and December is 11.
69
70- method : getEventsInYear, array
71
72year[int]: The year for which all events should be returned.
73
74- example : Events on December 5, 2015
75
76See `Titanium.Android.Calendar` for examples.
77
78
79**/
80
81#if androidos
82@:native("Titanium.Android.Calendar.Calendar")
83extern class Calendar
84{		
85	// properties
86	public var name:String;
87	public var id:String;
88	public var selected:Bool;
89	public var hidden:Bool;
90
91	// methods
92	public function createEvent(properties:Dynamic):Event;
93	public function getEventsBetweenDates(date1:Date, date2:Date):Array<Event>;
94	public function getEventById(id:Int):Event;
95	public function getEventsInDate(year:Int, month:Int, day:Int):Array<Event>;
96	public function getEventsInMonth(year:Int, month:Int):Array<Event>;
97	public function getEventsInYear(year:Int):Array<Event>;
98}
99#end