Package psiprobe.tools
Class TimeExpression
- java.lang.Object
-
- psiprobe.tools.TimeExpression
-
public final class TimeExpression extends Object
The Class TimeExpression.
-
-
Constructor Summary
Constructors Modifier Constructor Description private
TimeExpression()
Prevent Instantiation.
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static String
cronExpression(long period, long phase)
Cron expression.static String
cronExpression(String periodExpression, String phaseExpression)
Cron expression.private static String
cronSubexpression(long period, long phase)
Cron subexpression.static long
dataPoints(long period, long span)
Data points.static long
dataPoints(String periodExpression, String spanExpression)
Data points.static long
inSeconds(String expression)
In seconds.private static int
multiplier(char unit)
Multiplier.
-
-
-
Method Detail
-
dataPoints
public static long dataPoints(String periodExpression, String spanExpression)
Data points.- Parameters:
periodExpression
- the period expressionspanExpression
- the span expression- Returns:
- the long
-
dataPoints
public static long dataPoints(long period, long span)
Data points.- Parameters:
period
- the periodspan
- the span- Returns:
- the long
-
cronExpression
public static String cronExpression(String periodExpression, String phaseExpression)
Cron expression.- Parameters:
periodExpression
- the period expressionphaseExpression
- the phase expression- Returns:
- the string
-
cronExpression
public static String cronExpression(long period, long phase)
Cron expression.- Parameters:
period
- the periodphase
- the phase- Returns:
- the string
-
cronSubexpression
private static String cronSubexpression(long period, long phase)
Cron subexpression.- Parameters:
period
- the periodphase
- the phase- Returns:
- the string
-
inSeconds
public static long inSeconds(String expression)
In seconds.- Parameters:
expression
- the expression- Returns:
- the long
-
multiplier
private static int multiplier(char unit)
Multiplier.- Parameters:
unit
- the unit- Returns:
- the int
-
-