Quote:
API dcoumentation:
Period.name() Name of predefined constant exactly how it was defined or null if it's custom period
if getting a list of all compliant periods by calling Period.generateAllCompliantPeriods(), for all non-basic periods period.name() returns the name of the UNIT.
Example:
period "2 Hours" period.name() = "HOURS"
period "6 Hours" period.name() = "HOURS"
..
Period "2 Days" period.name()= "DAYS"
...
It's not critical as the names shouldn't be used in the processing logic, but it would be good for consistency if you could return the name in a style equivalent to the basic periods ("TWO_HOURS", "SIX_HOURS", "TWO_DAYS", ...) or return null for all non-basic periods as described in the API documentation.
Best, RR.