MCPcopy Create free account
hub / github.com/amazon-ion/ion-java / checkAndCastYear

Method checkAndCastYear

src/main/java/com/amazon/ion/Timestamp.java:2889–2897  ·  view source on GitHub ↗
(int year)

Source from the content-addressed store, hash-verified

2887 }
2888
2889 private static short checkAndCastYear(int year)
2890 {
2891 if (year < 1 || year > 9999)
2892 {
2893 throw new IllegalArgumentException(String.format("Year %s must be between 1 and 9999 inclusive", year));
2894 }
2895
2896 return (short) year;
2897 }
2898
2899 private static byte checkAndCastMonth(int month)
2900 {

Callers 3

TimestampMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected