Example usage for org.joda.time LocalTime fromCalendarFields

List of usage examples for org.joda.time LocalTime fromCalendarFields

Introduction

In this page you can find the example usage for org.joda.time LocalTime fromCalendarFields.

Prototype

public static LocalTime fromCalendarFields(Calendar calendar) 

Source Link

Document

Constructs a LocalTime from a java.util.Calendar using exactly the same field values.

Usage

From source file:com.kccomy.orgar.ui.editor.NodeEditorFragment.java

License:Apache License

@Override
public void onTimeSet(RadialPickerLayout view, int hourOfDay, int minute, int second) {
    Calendar calendar = Calendar.getInstance();
    calendar.set(0, 0, 0, hourOfDay, minute, second);
    LocalTime time = LocalTime.fromCalendarFields(calendar);
    scheduledTimeBtn.setText(time.toString(TIME_FORMAT));
    scheduledTime = time;//from w  w  w  .  j  a v a2  s.  c om
    scheduledDate.withTime(time.getHourOfDay(), time.getMinuteOfHour(), 0, 0);
}