Java Code Examples for org.joda.time.DateTimeFieldType#minuteOfHour()
The following examples show how to use
org.joda.time.DateTimeFieldType#minuteOfHour() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: TestISODateTimeFormat.java From astor with GNU General Public License v2.0 | 5 votes |
public void testFormat_time_partial() { Partial dt = new Partial( new DateTimeFieldType[] {DateTimeFieldType.hourOfDay(), DateTimeFieldType.minuteOfHour(), DateTimeFieldType.secondOfMinute(), DateTimeFieldType.millisOfSecond()}, new int[] {10, 20, 30, 40}); assertEquals("10:20:30.040", ISODateTimeFormat.time().print(dt)); }
Example 2
Source File: TestISODateTimeFormat.java From astor with GNU General Public License v2.0 | 5 votes |
public void testFormat_timeNoMillis_partial() { Partial dt = new Partial( new DateTimeFieldType[] {DateTimeFieldType.hourOfDay(), DateTimeFieldType.minuteOfHour(), DateTimeFieldType.secondOfMinute(), DateTimeFieldType.millisOfSecond()}, new int[] {10, 20, 30, 40}); assertEquals("10:20:30", ISODateTimeFormat.timeNoMillis().print(dt)); }
Example 3
Source File: TestISODateTimeFormat.java From astor with GNU General Public License v2.0 | 5 votes |
public void testFormat_time_partial() { Partial dt = new Partial( new DateTimeFieldType[] {DateTimeFieldType.hourOfDay(), DateTimeFieldType.minuteOfHour(), DateTimeFieldType.secondOfMinute(), DateTimeFieldType.millisOfSecond()}, new int[] {10, 20, 30, 40}); assertEquals("10:20:30.040", ISODateTimeFormat.time().print(dt)); }
Example 4
Source File: TestISODateTimeFormat.java From astor with GNU General Public License v2.0 | 5 votes |
public void testFormat_timeNoMillis_partial() { Partial dt = new Partial( new DateTimeFieldType[] {DateTimeFieldType.hourOfDay(), DateTimeFieldType.minuteOfHour(), DateTimeFieldType.secondOfMinute(), DateTimeFieldType.millisOfSecond()}, new int[] {10, 20, 30, 40}); assertEquals("10:20:30", ISODateTimeFormat.timeNoMillis().print(dt)); }
Example 5
Source File: SummariesManagementDA.java From fenixedu-academic with GNU Lesser General Public License v3.0 | 5 votes |
public ActionForward prepareEditSummary(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response) throws FenixServiceException { Professorship teacherLogged = ((Professorship) request.getAttribute("loggedTeacherProfessorship")); DynaActionForm dynaActionForm = (DynaActionForm) form; Summary summary = getSummaryFromParameter(request); SummaryType summaryType; if (summary.isExtraSummary()) { summaryType = SummaryType.EXTRA_SUMMARY; request.setAttribute("notShowLessonPlanningsAndSummaries", Boolean.TRUE); } else { summaryType = SummaryType.NORMAL_SUMMARY; } DateTimeFieldType[] dateTimeFieldTypes = { DateTimeFieldType.hourOfDay(), DateTimeFieldType.minuteOfHour() }; HourMinuteSecond time = summary.getSummaryHourHourMinuteSecond(); int[] timeArray = { time.getHour(), time.getMinuteOfHour() }; Partial timePartial = new Partial(dateTimeFieldTypes, timeArray); SummariesManagementBean bean = new SummariesManagementBean(summary.getTitle(), summary.getSummaryText(), summary.getStudentsNumber(), summaryType, summary.getProfessorship(), summary.getTeacherName(), summary.getTeacher(), summary.getShift(), summary.getLesson(), summary.getSummaryDateYearMonthDay(), summary.getRoom(), timePartial, summary, teacherLogged, summary.getSummaryType(), summary.getTaught(), summary.getOnlineLesson()); return goToSummaryManagementPageAgain(mapping, request, dynaActionForm, bean); }