static HijriAdjustment from ( String variant ) { int index = variant . indexOf ( ' ' ) ; if ( index == - 1 ) { return new HijriAdjustment ( variant , 0 ) ; } else { try { int adjustment = Integer . parseInt ( variant . substring ( index + 1 ) ) ; return new HijriAdjustment ( variant . substring ( 0 , index ) , adjustment ) ; } catch ( NumberFormatException nfe ) { throw new ChronoException ( "Invalid day adjustment: " + variant ) ; } } }
also called by Hijri calendar systems