I want to store an intervall. It can be months, weeks, hours, minutes and seconds. But maybe only hours, minutes and seconds. It is a regularity, repeat time, example after every 8h 34m an action runs. Not cuba action, not in my project, I only stores it’s repeat time.
So I guess I should store it in seconds, as integer. Just should display in a clear format, converted. First only the displaying the question, maybe later the edit. Example: the integer is 26700 and in the browser sceen table shows 7h 25m.
Any idea about it? Or maybe a built-in Cuba function?
The regex above is for expressions like “10d 5h 20m 40s”, or “5h 20m”.
I’d suggest installing a regex tester plugin for IntelliJ like “RegexPlugin”, so you will be able to create and test regex easily. See also Pattern (Java Platform SE 8 )