-2

スタックトレース:

org.springframework.beans.factory.NoUniqueBeanDefinitionException: No qualifying bean of type [org.vliv.dao.MySqlLogDao] is defined: expected single matching bean but found 2: mySqlLogDaoImpl,mySqlLogDao

Java コード:

public interface MysqlDao {
    public void regstr();
}

@Repository
@Transactional
public class MysqlDaoImpl { 
    public void regstr() {}
}

@Controller
public class Brand {
    @Autowired
    MySqlDao mySqlDao;//gives exception
}
4

1 に答える 1