Codota Logo
Event.setStart
Code IndexAdd Codota to your IDE (free)

How to use
setStart
method
in
com.google.api.services.calendar.model.Event

Best Java code snippets using com.google.api.services.calendar.model.Event.setStart (Showing top 12 results out of 315)

  • Common ways to obtain Event
private void myMethod () {
Event e =
  • Codota Iconnew Event()
  • Smart code suggestions by Codota
}
origin: google/data-transfer-project

static Event convertToGoogleCalendarEvent(CalendarEventModel eventModel) {
 Event event = new Event()
   .setLocation(eventModel.getLocation())
   .setDescription(eventModel.getTitle())
   .setSummary(eventModel.getNotes())
   .setStart(getEventDateTime(eventModel.getStartTime()))
   .setEnd(getEventDateTime(eventModel.getEndTime()));
 if (eventModel.getAttendees() != null) {
  event.setAttendees(eventModel.getAttendees().stream()
    .map(GoogleCalendarImporter::transformToEventAttendee)
    .collect(Collectors.toList()));
 }
 return event;
}
origin: google/google-api-java-client-samples

private static Event newEvent() {
 Event event = new Event();
 event.setSummary("New Event");
 Date startDate = new Date();
 Date endDate = new Date(startDate.getTime() + 3600000);
 DateTime start = new DateTime(startDate, TimeZone.getTimeZone("UTC"));
 event.setStart(new EventDateTime().setDateTime(start));
 DateTime end = new DateTime(endDate, TimeZone.getTimeZone("UTC"));
 event.setEnd(new EventDateTime().setDateTime(end));
 return event;
}
origin: io.syndesis.connector/connector-google-calendar

  Date startMidDate = dateFormat.parse(composedTime);
  DateTime start = new DateTime(startMidDate);
  event.setStart(new EventDateTime().setDateTime(start));
} else {
  composedTime = startDate;
  DateTime startDateTime = new DateTime(composedTime);
  EventDateTime startEventDateTime = new EventDateTime().setDate(startDateTime);
  event.setStart(startEventDateTime);
origin: io.syndesis.connector/connector-google-calendar

  Date startMidDate = dateFormat.parse(composedTime);
  DateTime start = new DateTime(startMidDate);
  event.setStart(new EventDateTime().setDateTime(start));
} else {
  composedTime = startDate;
  DateTime startDateTime = new DateTime(composedTime);
  EventDateTime startEventDateTime = new EventDateTime().setDate(startDateTime);
  event.setStart(startEventDateTime);
origin: NovaFox161/DisCal-Discord-Bot

event.setStart(start.setTimeZone(cal.getTimeZone()));
origin: NovaFox161/DisCal-Discord-Bot

event.setStart(start.setTimeZone(cal.getTimeZone()));
origin: NovaFox161/DisCal-Discord-Bot

event.setStart(start.setTimeZone(cal.getTimeZone()));
origin: NovaFox161/DisCal-Discord-Bot

event.setStart(start.setTimeZone(cal.getTimeZone()));
origin: NovaFox161/DisCal-Discord-Bot

event.setStart(start.setTimeZone(cal.getTimeZone()));
origin: NovaFox161/DisCal-Discord-Bot

event.setStart(start.setTimeZone(cal.getTimeZone()));
origin: synyx/urlaubsverwaltung

private static void fillEvent(Absence absence, Event event) {
  event.setSummary(absence.getEventSubject());
  EventAttendee eventAttendee = new EventAttendee();
  eventAttendee.setEmail(absence.getPerson().getEmail());
  eventAttendee.setDisplayName(absence.getPerson().getNiceName());
  event.setAttendees(Collections.singletonList(eventAttendee));
  EventDateTime startEventDateTime;
  EventDateTime endEventDateTime;
  if (absence.isAllDay()) {
    // To create an all-day event, you must use setDate() having created DateTime objects using a String
    DateFormat dateFormat = new SimpleDateFormat(DATE_PATTERN_YYYY_MM_DD);
    String startDateStr = dateFormat.format(absence.getStartDate());
    String endDateStr = dateFormat.format(absence.getEndDate());
    DateTime startDateTime = new DateTime(startDateStr);
    DateTime endDateTime = new DateTime(endDateStr);
    startEventDateTime = new EventDateTime().setDate(startDateTime);
    endEventDateTime = new EventDateTime().setDate(endDateTime);
  } else {
    DateTime dateTimeStart = new DateTime(absence.getStartDate());
    DateTime dateTimeEnd = new DateTime(absence.getEndDate());
    startEventDateTime = new EventDateTime().setDateTime(dateTimeStart);
    endEventDateTime = new EventDateTime().setDateTime(dateTimeEnd);
  }
  event.setStart(startEventDateTime);
  event.setEnd(endEventDateTime);
}
origin: gdenning/exchange-sync

private void populateEventFromAppointmentDto(final AppointmentDto appointmentDto, final Event event) {
  event.setSummary(appointmentDto.getSummary());
  event.setDescription(appointmentDto.getDescription());
  event.setStart(convertToEventDateTime(appointmentDto.getStart(), appointmentDto.isAllDay(), calendarTimeZone));
  event.setEnd(convertToEventDateTime(appointmentDto.getEnd(), appointmentDto.isAllDay(), calendarTimeZone));
  event.setLocation(appointmentDto.getLocation());
com.google.api.services.calendar.modelEventsetStart

Popular methods of Event

  • <init>
  • getStart
  • getSummary
  • getEnd
  • getId
  • setEnd
  • setSummary
  • getDescription
  • getLocation
  • setDescription
  • setLocation
  • getRecurrence
  • setLocation,
  • getRecurrence,
  • getColorId,
  • setAttendees,
  • setRecurrence,
  • getAttendees,
  • getLocked,
  • setColorId,
  • setId

Popular in Java

  • Updating database using SQL prepared statement
  • startActivity (Activity)
  • setScale (BigDecimal)
    Returns a BigDecimal whose scale is the specified value, and whose value is numerically equal to thi
  • setContentView (Activity)
  • ObjectMapper (com.fasterxml.jackson.databind)
    This mapper (or, data binder, or codec) provides functionality for converting between Java objects (
  • GridLayout (java.awt)
    The GridLayout class is a layout manager that lays out a container's components in a rectangular gri
  • DecimalFormat (java.text)
    DecimalFormat is a concrete subclass ofNumberFormat that formats decimal numbers. It has a variety o
  • SimpleDateFormat (java.text)
    Formats and parses dates in a locale-sensitive manner. Formatting turns a Date into a String, and pa
  • ExecutorService (java.util.concurrent)
    An Executor that provides methods to manage termination and methods that can produce a Future for tr
  • StringUtils (org.apache.commons.lang)
    Operations on java.lang.String that arenull safe. * IsEmpty/IsBlank - checks if a String contains
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now