Package de.smoofy.core.api.time
Schnittstelle ITimeHandler
public interface ITimeHandler
-
Methodenübersicht
Modifizierer und TypMethodeBeschreibungboolean
beforeToday
(String time) Get theDateTimeFormatter
.format
(LocalDateTime localDateTime) Get the current time.format
(LocalDateTime localDateTime, DateTimeFormatter dateTimeFormatter) Get the current time.boolean
localDateTime
(long millis) Get the LocalDateTime of millis.timeBack
(int years, int months, int days, int hours, int minutes, int seconds) Get the time in the past.Get the time in the past.timeIn
(int years, int months, int days, int hours, int minutes, int seconds) Get the time in the future.Get the time in the future.timeNow()
Get the current time.timeString
(String time) Get the time as a string.timeZone
(ICorePlayer player) Get the time zone in players language.today()
Get the date of today.zero()
Get the zero time.
-
Methodendetails
-
timeNow
String timeNow()Get the current time.- Gibt zurück:
- the current time
-
format
Get the current time.- Parameter:
localDateTime
- the LocalDateTime- Gibt zurück:
- the current time formatted
-
format
Get the current time.- Parameter:
localDateTime
- the timedateTimeFormatter
- the format- Gibt zurück:
- the current time in the format
-
timeIn
Get the time in the future.- Parameter:
years
- the yearsmonths
- the monthsdays
- the dayshours
- the hoursminutes
- the minutesseconds
- the seconds- Gibt zurück:
- the time
-
timeIn
Get the time in the future.- Parameter:
time
- the timetimeUnit
- the time unit- Gibt zurück:
- the time
-
timeBack
Get the time in the past.- Parameter:
years
- the yearsmonths
- the monthsdays
- the dayshours
- the hoursminutes
- the minutesseconds
- the seconds- Gibt zurück:
- the time
-
timeBack
Get the time in the past.- Parameter:
time
- the timetimeUnit
- the time unit- Gibt zurück:
- the time
-
zero
String zero()Get the zero time.- Gibt zurück:
- "-1"
-
today
String today()Get the date of today. (dd. MM yyyy)- Gibt zurück:
- the date of today
-
timeString
Get the time as a string. Interesting for a punish system.- Parameter:
time
- the time- Gibt zurück:
- the time as a string
-
later
- Parameter:
time
- the time- Gibt zurück:
- true if the time is after now, otherwise false
-
beforeToday
- Parameter:
time
- the time- Gibt zurück:
- true if the time is before now, otherwise false
-
timeZone
Get the time zone in players language.- Parameter:
player
- the player- Gibt zurück:
- the time zone
-
localDateTime
Get the LocalDateTime of millis.- Gibt zurück:
- the
LocalDateTime
-
dateTimeFormatter
DateTimeFormatter dateTimeFormatter()Get theDateTimeFormatter
.- Gibt zurück:
- the
DateTimeFormatter
(dd MM yyyy, HH:mm:ss)
-