I am using a hashmap and method type changes to the list for the listeners to track the audience is shown below. IDE is giving a warning
[rawtypes] Raw type found: java.lang.Class Common Category missing type parameter for java.lang.Class & lt; T & gt; What kind of class should be specified to address the alert?
Private Hashmaps T> cls, ChangeListener listener) {if (class class change listers constants (CLS)) {classChangeListeners.put (CLS, New TreeSet & lt; ChangeListener & gt; ()); } ClassChangeListeners.get (CLS) .add (listener); } / Code> es which are working with you, instead of category instead of class . In some cases, you want to wildcard it, class or parametrize it, class - But usually class will be enough, and it's hard to guess what you really want from a small snippet.
In addition, it seems that you are using a group with a group. You can use the facility with which this functionality has been built and makes it very good to work with.
Comments
Post a Comment