Get user calendar using OutlookClient

后端 未结 2 707
失恋的感觉
失恋的感觉 2020-12-22 07:12

I\'m using Outlook-SDK-Android (https://github.com/OfficeDev/Outlook-SDK-Android) to talk with Outlook Calendar REST API (https://msdn.microsoft.com/en-us/office/office365/a

2条回答
  •  余生分开走
    2020-12-22 08:01

    There is a select method:

    public OrcCollectionFetcher select(String select)

    in OrcCollectionFetcher class, so you can call it like this:

    mClient.getMe()                
                        .getCalendarView()
                        .addParameter("startDateTime", startDate)
                        .addParameter("endDateTime", endDate)
                        .select("Subject")
                        .read()
    

    To get events from resource try this:

                final List events = outlookClient
                    .getUsers()
                    .getById("meetingRoom@company.com")
                    .getCalendarView()
                    .addParameter("startDateTime", startDate)
                    .addParameter("endDateTime", endDate)
                    .read()
    

提交回复
热议问题