The type List is not generic

错误:The type List is not generic; it cannot be parameterized with arguments <Activity>

代码如下:

    public List<Activity> getAllActivity() {
        return (List<Activity>) getSqlMapClientTemplate().queryForList("Activity.getAllActivity");
    }

 

原因:import java.awt.List;不支持泛型。修改引用uitl包,import java.util.List;

你可能感兴趣的:(list,import)