MCPcopy Create free account
hub / github.com/MenoData/Time4J / from

Method from

base/src/main/java/net/time4j/PlainDate.java:924–932  ·  view source on GitHub ↗
(GregorianDate date)

Source from the content-addressed store, hash-verified

922 * @return PlainDate
923 */
924 public static PlainDate from(GregorianDate date) {
925
926 if (date instanceof PlainDate) {
927 return (PlainDate) date;
928 } else {
929 return PlainDate.of(date.getYear(), date.getMonth(), date.getDayOfMonth());
930 }
931
932 }
933
934 /**
935 * <p>Short cut for {@code TemporalType.LOCAL_DATE.translate(date)}. </p>

Callers 15

fromLocalDateMethod · 0.95
threetenComparisonMethod · 0.95
fromMethod · 0.95
applyMethod · 0.95
createFromMethod · 0.95
todayMethod · 0.95
betweenMethod · 0.95
sinceMethod · 0.95
untilMethod · 0.95
atomicMethod · 0.95
emptyWithAnchorMethod · 0.95

Calls 15

ofMethod · 0.95
floorDivideMethod · 0.95
toPackedDateMethod · 0.95
readYearMethod · 0.95
readMonthMethod · 0.95
readDayOfMonthMethod · 0.95
getYearMethod · 0.65
getMonthMethod · 0.65
getDayOfMonthMethod · 0.65
translateMethod · 0.65
getPosixTimeMethod · 0.65
getNanosecondMethod · 0.65

Tested by 3

fromLocalDateMethod · 0.76
threetenComparisonMethod · 0.76