示例#1
0
 @Override
 public <T> List<T> getResource(ModelUser user, EResourceType type) {
   @SuppressWarnings("unchecked")
   IServBaseResource<T> servResource = mapResource.get(type);
   if (servResource == null) {
     return new ArrayList<T>();
   }
   return servResource.getResource(user);
 }
示例#2
0
 @Override
 public <T> boolean addServResource(IServBaseResource<T> servResource) {
   mapResource.put(servResource.getType(), servResource);
   return true;
 }