So I have this code...
SimpleDateFormat timeFormatter = new SimpleDateFormat("HH:minutes");
poaTimeDataText.setText(timeFormatter.format(getIntent().getLongExtra(
ShiftLogsFragment.EXTRA_POA_TIME, 0)));
Now instead of displaying for example 02:40, I want it to display like 2 hours 40 minutes. However, I have tried, changing the pattern to "HH hours mm minutes"
but the compiler does not like that. How can I get the desired result?
EDIT: Would be nice if it accounts for singular or plural like hours or hour, minute (if 0 or 1) or minutes (if 2 or more)