com.google.api.services.calendar.model.Event.getSummary()方法的使用及代码示例

x33g5p2x  于2022-01-19 转载在 其他  
字(5.0k)|赞(0)|评价(0)|浏览(176)

本文整理了Java中com.google.api.services.calendar.model.Event.getSummary()方法的一些代码示例,展示了Event.getSummary()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Event.getSummary()方法的具体详情如下:
包路径:com.google.api.services.calendar.model.Event
类名称:Event
方法名:getSummary

Event.getSummary介绍

暂无

代码示例

代码示例来源:origin: google/data-transfer-project

  1. private static CalendarEventModel convertToCalendarEventModel(String id, Event eventData) {
  2. List<EventAttendee> attendees = eventData.getAttendees();
  3. List<String> recurrenceRulesStrings = eventData.getRecurrence();
  4. return new CalendarEventModel(
  5. id,
  6. eventData.getDescription(),
  7. eventData.getSummary(),
  8. attendees == null
  9. ? null
  10. : attendees
  11. .stream()
  12. .map(GoogleCalendarExporter::transformToModelAttendee)
  13. .collect(Collectors.toList()),
  14. eventData.getLocation(),
  15. getEventTime(eventData.getStart()),
  16. getEventTime(eventData.getEnd()),
  17. recurrenceRulesStrings == null ? null : getRecurrenceRule(recurrenceRulesStrings));
  18. }

代码示例来源:origin: synyx/urlaubsverwaltung

  1. @Override
  2. public Optional<String> add(Absence absence, CalendarSettings calendarSettings) {
  3. googleCalendarClient = getOrCreateGoogleCalendarClient();
  4. if (googleCalendarClient != null) {
  5. GoogleCalendarSettings googleCalendarSettings =
  6. settingsService.getSettings().getCalendarSettings().getGoogleCalendarSettings();
  7. String calendarId = googleCalendarSettings.getCalendarId();
  8. try {
  9. Event eventToCommit = new Event();
  10. fillEvent(absence, eventToCommit);
  11. Event eventInCalendar = googleCalendarClient.events().insert(calendarId, eventToCommit).execute();
  12. LOG.info(String.format("Event %s for '%s' added to calendar '%s'.", eventInCalendar.getId(),
  13. absence.getPerson().getNiceName(), eventInCalendar.getSummary()));
  14. return Optional.of(eventInCalendar.getId());
  15. } catch (IOException ex) {
  16. LOG.warn(String.format("An error occurred while trying to add appointment to calendar %s", calendarId), ex);
  17. mailService.sendCalendarSyncErrorNotification(calendarId, absence, ex.toString());
  18. }
  19. }
  20. return Optional.empty();
  21. }

代码示例来源:origin: io.syndesis.connector/connector-google-calendar

  1. if (event != null) {
  2. if (ObjectHelper.isNotEmpty(event.getSummary())) {
  3. model.setTitle(event.getSummary());

代码示例来源:origin: io.syndesis.connector/connector-google-calendar

  1. if (event != null) {
  2. if (ObjectHelper.isNotEmpty(event.getSummary())) {
  3. model.setTitle(event.getSummary());

代码示例来源:origin: io.syndesis.connector/connector-google-calendar

  1. if (event != null) {
  2. if (ObjectHelper.isNotEmpty(event.getSummary())) {
  3. model.setTitle(event.getSummary());

代码示例来源:origin: io.syndesis.connector/connector-google-calendar

  1. if (event != null) {
  2. if (ObjectHelper.isNotEmpty(event.getSummary())) {
  3. model.setTitle(event.getSummary());

代码示例来源:origin: NovaFox161/DisCal-Discord-Bot

  1. jo.put("epochEnd", e.getEnd().getDateTime().getValue());
  2. jo.put("timezone", tz);
  3. jo.put("summary", e.getSummary());
  4. jo.put("description", e.getDescription());
  5. if (e.getLocked() != null)

代码示例来源:origin: NovaFox161/DisCal-Discord-Bot

  1. jo.put("epochEnd", e.getEnd().getDateTime().getValue());
  2. jo.put("timezone", tz);
  3. jo.put("summary", e.getSummary());
  4. jo.put("description", e.getDescription());
  5. if (e.getLocked() != null)

代码示例来源:origin: gsuitedevs/java-samples

  1. public static void main(String... args) throws IOException, GeneralSecurityException {
  2. // Build a new authorized API client service.
  3. final NetHttpTransport HTTP_TRANSPORT = GoogleNetHttpTransport.newTrustedTransport();
  4. Calendar service = new Calendar.Builder(HTTP_TRANSPORT, JSON_FACTORY, getCredentials(HTTP_TRANSPORT))
  5. .setApplicationName(APPLICATION_NAME)
  6. .build();
  7. // List the next 10 events from the primary calendar.
  8. DateTime now = new DateTime(System.currentTimeMillis());
  9. Events events = service.events().list("primary")
  10. .setMaxResults(10)
  11. .setTimeMin(now)
  12. .setOrderBy("startTime")
  13. .setSingleEvents(true)
  14. .execute();
  15. List<Event> items = events.getItems();
  16. if (items.isEmpty()) {
  17. System.out.println("No upcoming events found.");
  18. } else {
  19. System.out.println("Upcoming events");
  20. for (Event event : items) {
  21. DateTime start = event.getStart().getDateTime();
  22. if (start == null) {
  23. start = event.getStart().getDate();
  24. }
  25. System.out.printf("%s (%s)\n", event.getSummary(), start);
  26. }
  27. }
  28. }
  29. }

代码示例来源:origin: NovaFox161/DisCal-Discord-Bot

  1. jo.put("epochEnd", e.getEnd().getDateTime().getValue());
  2. jo.put("timezone", tz);
  3. jo.put("summary", e.getSummary());
  4. jo.put("description", e.getDescription());
  5. if (e.getLocked() != null)

代码示例来源:origin: NovaFox161/DisCal-Discord-Bot

  1. public static PreEvent copyEvent(long guildId, Event event) {
  2. PreEvent pe = new PreEvent(guildId);
  3. pe.setSummary(event.getSummary());
  4. pe.setDescription(event.getDescription());
  5. pe.setLocation(event.getLocation());
  6. if (event.getColorId() != null)
  7. pe.setColor(EventColor.fromNameOrHexOrID(event.getColorId()));
  8. else
  9. pe.setColor(EventColor.RED);
  10. pe.setEventData(DatabaseManager.getManager().getEventData(guildId, event.getId()));
  11. return pe;
  12. }
  13. }

代码示例来源:origin: gdenning/exchange-sync

  1. result.setSummary(event.getSummary());
  2. result.setDescription(event.getDescription());
  3. result.setStart(convertToJodaDateTime(event.getStart()));

代码示例来源:origin: NovaFox161/DisCal-Discord-Bot

  1. if (e.getSummary() != null)
  2. summary = e.getSummary();

相关文章