我需要初始化一个像Map x<Apartment,Vector<Expense>>
它可以让我,如果我@override
地图方法初始化一个Map <富,矢量<Bar>> - Java 7的
Description Resource Path Location Type
The type new Map<Apartment,Vector<Expense>>(){} must implement the inherited abstract method Map<Apartment,Vector<Expense>>.isEmpty() Repository.java /proj_individual/src/repo line 12 Java Problem
The type new Map<Apartment,Vector<Expense>>(){} must implement the inherited abstract method Map<Apartment,Vector<Expense>>.size() Repository.java /proj_individual/src/repo line 12 Java Problem
The type new Map<Apartment,Vector<Expense>>(){} must implement the inherited abstract method Map<Apartment,Vector<Expense>>.keySet() Repository.java /proj_individual/src/repo line 12 Java Problem
The type new Map<Apartment,Vector<Expense>>(){} must implement the inherited abstract method Map<Apartment,Vector<Expense>>.remove(Object) Repository.java /proj_individual/src/repo line 12 Java Problem
The type new Map<Apartment,Vector<Expense>>(){} must implement the inherited abstract method Map<Apartment,Vector<Expense>>.entrySet() Repository.java /proj_individual/src/repo line 12 Java Problem
The type new Map<Apartment,Vector<Expense>>(){} must implement the inherited abstract method Map<Apartment,Vector<Expense>>.putAll(Map<? extends Apartment,? extends Vector<Expense>>) Repository.java /proj_individual/src/repo line 12 Java Problem
The type new Map<Apartment,Vector<Expense>>(){} must implement the inherited abstract method Map<Apartment,Vector<Expense>>.values() Repository.java /proj_individual/src/repo line 12 Java Problem
The type new Map<Apartment,Vector<Expense>>(){} must implement the inherited abstract method Map<Apartment,Vector<Expense>>.clear() Repository.java /proj_individual/src/repo line 12 Java Problem
The type new Map<Apartment,Vector<Expense>>(){} must implement the inherited abstract method Map<Apartment,Vector<Expense>>.get(Object) Repository.java /proj_individual/src/repo line 12 Java Problem
The type new Map<Apartment,Vector<Expense>>(){} must implement the inherited abstract method Map<Apartment,Vector<Expense>>.containsKey(Object) Repository.java /proj_individual/src/repo line 12 Java Problem
The type new Map<Apartment,Vector<Expense>>(){} must implement the inherited abstract method Map<Apartment,Vector<Expense>>.containsValue(Object) Repository.java /proj_individual/src/repo line 12 Java Problem
The type new Map<Apartment,Vector<Expense>>(){} must implement the inherited abstract method Map<Apartment,Vector<Expense>>.put(Apartment, Vector<Expense>) Repository.java /proj_individual/src/repo line 12 Java Problem
但我在互联网上阅读地图不是接口,它是一个类,我做错了,或者这是必须完成的方式?
嗯..什么? '地图是一类' - 你在互联网上读到这个? –
地图是一个接口。 (http://docs.oracle.com/javase/6/docs/api/java/util/Map.html) –
怎么样'地图<公寓,矢量> myMap = new HashMap <公寓,矢量>( )'?并看看JB Nizets的答案。你可以找到你需要的所有信息。 –
semTex