Type interface is not known to the MapperRegistry????

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

Type interface is not known to the MapperRegistry????

I don't know why when i running Spring + MyBatis 3.1, i got this message:
"Caused by: org.apache.ibatis.binding.BindingException: Type interface MessageIdMap is not known to the MapperRegistry."
I've already checked Interface, and every thing is normal, and the same runs good.

This is DAO:

public class MessageIdDAOImpl extends SqlSessionDaoSupport implements
                MessageIdDAO, Serializable {

        private static final long serialVersionUID = 1L;

        public List<MessageIdDTO> selectMessageIdList(
                        String screenType) {
                List<MessageIdDTO> rtnValue = getSqlSession().getMapper(
                return rtnValue;

 And this is Xml:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper
  PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
        <mapper namespace="dao.map.MessageIdMap">
        <resultMap id="MResult" type="MessageIdDTO">
                <result column="MESSAGE_ID" property="messageId"/>
        <select id="selectAAA" resultMap="MResult">
        My SQL Select

And here is my Mapper:

public interface MessageIdMap {
        public List<MessageIdDTO> selectMessageIdList(
                        String screenType);

Please help me why ? Thank in advance.