List of usage examples for org.joda.time MutableDateTime setDate
public void setDate(final int year, final int monthOfYear, final int dayOfMonth)
From source file:org.agatom.springatom.data.hades.model.appointment.NAppointment.java
License:Open Source License
public NAppointment setBeginDate(final LocalDate localDate) { this.requireBeginDate(); final MutableDateTime mutableDateTime = this.begin.toMutableDateTime(); mutableDateTime.setDate(localDate.getYear(), localDate.getMonthOfYear(), localDate.getDayOfMonth()); this.begin = mutableDateTime.toDateTime(); return this; }
From source file:org.agatom.springatom.data.hades.model.appointment.NAppointment.java
License:Open Source License
public NAppointment setEndDate(final LocalDate localDate) { this.requireEndDate(); final MutableDateTime mutableDateTime = this.end.toMutableDateTime(); mutableDateTime.setDate(localDate.getYear(), localDate.getMonthOfYear(), localDate.getDayOfMonth()); this.end = mutableDateTime.toDateTime(); return this; }
From source file:org.apache.beam.sdk.io.gcp.spanner.MutationGroupEncoder.java
License:Apache License
private static int encodeDate(Date date) { MutableDateTime jodaDate = new MutableDateTime(); jodaDate.setDate(date.getYear(), date.getMonth(), date.getDayOfMonth()); return Days.daysBetween(MIN_DATE, jodaDate).getDays(); }
From source file:org.mongoste.util.DateUtil.java
License:Open Source License
public static DateTime buildUTCDate(int year, int month, int day) { MutableDateTime mdt = new DateTime(DateTimeZone.UTC).toMutableDateTime(); mdt.setDate(year, month, day); return trimTime(mdt.toDateTime()); }