Java Calendar getDisplayNames方法 Java Calendar getDisplayName方法 Java示例-创建一个套接字Socket Java Calendar getDisplayNames方法 package com.codingdict; import java.util.*; public class CalendarDemo { public static void main(String[] args) { // create calendar and locale Calendar now = Calendar.getInstance(); Locale locale = Locale.getDefault(); // call the getdisplaynames method Map< String, Integer> representations = now.getDisplayNames(Calendar.DAY_OF_WEEK, Calendar.LONG, locale); NavigableMap< String, Integer> navMap = new TreeMap< String, Integer>(representations); // print the results System.out.printf("Whole list:%n%s%n", navMap); } } Java Calendar getDisplayName方法 Java示例-创建一个套接字Socket