---
title: "Eclipse中生成iBatis代码以及配置文件"
author: "flyer2010"
date: "2010-08-10T21:51:51Z"
tags: ["Apache", "Eclipse", "Spring", "XML", "iBATIS"]
categories: ["企业架构"]
slug: "eclipse-ibatis"
draft: false
lastmod: "2010-08-10T21:51:51Z"
id: 734057
url: "https://flyer2010.iteye.com/blog/734057"
---

最近项目在使用spring+ibatis，ibatis是比较不错的框架，但是配置sqlmap的时候还是要花一些时间的，为了提高一点效率，上网找了下eclipse中自动生成ibatis相关代码的插件，还是挺不错的。 1.安装插件 一.安装插件 eclipse-&gt;Help&gt;Software Updates&gt;Find and Install-&gt;Search for new features to install-&gt;New Remote Site 地址：http://ibatis.apache.org/tools/abator 2.新建一个Eclipse项目,输入名字，然后选择文件&gt;新建&gt;ABator for iBatis configuration File，选择Location，并且键入File Name：abatorCsonfig.xml 修改abatorConfig.xml,把里面的相关“？”根据自己的实际情况替换. 例如：

4..在abatorCsonfig.xml上点击鼠标右键，选择Generate iBATIS Artifact，在src目录下会生成model、map、dao三个目录，文件也建立好了。