Similar to Getting a current quarter in Java this example takes it a step further. It uses Guava RangeMap and contains three methods getQuarter, getQuarterBeginDate and getQuarterEndDate.
Setup
Class
Get Quarter
Get Quarter Begin Date
Get Quarter End Date
Unit tests
Current quarter test
Current quarter begin test
Current quarter end test