ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Enrique Ferreyra <eferre...@gmail.com>
Subject Re: config files, where ?
Date Thu, 06 Apr 2006 17:57:28 GMT
ok, i like that but how do you reference the sqlmap.xml ?

I try put in package com.ccem.comun, and reference  like this:

                String resource = "/com/ccem/comun/SqlMap.xml";
                Reader reader = Resources.getResourceAsReader(resource);
                sqlMap = SqlMapClientBuilder.buildSqlMapClient(reader);

But i get:

java.io.IOException: Could not find resource 
/com/ccem/comun/SqlMapConfig.xml

help...
thanks!

Ted Schrader escribió:

>Hello,
>
>For my project I'm keeping the SQLMaps under a java package, like this:
>
>com.mycompany.myapp.sqlmaps
>
>Because this implies that the SQLMaps as part of the source, my build
>process includes them in the jar/war/ear.
>
>Ted
>
>On 06/04/06, Cimballi <cimballi.cimballi@gmail.com> wrote:
>  
>
>>Hi,
>>
>>I use a separate folder for configuration files and I put this folder
>>in the classpath.
>>Maybe there are better solutions...
>>
>>Cimballi
>>
>>
>>On 4/6/06, Enrique Ferreyra <eferreyra@gmail.com> wrote:
>>    
>>
>>>Hi, this is kind of newbie question...
>>>
>>>I have an application in serveral JARs, i would like to all share the
>>>ibatis files (sql maps)  but i dont know how, currently this apps are
>>>NetBeans project, and i put the files in the Project/Build/Classes
>>>because i reference the file whitout path, the problem is if i do clean
>>>project NetBeans delete that dir, also if i run the generated jar the
>>>app cant find the files...
>>>
>>>Where is the best place to put this files in this situation, and how
>>>reference to it ?
>>>
>>>Thanks
>>>
>>>--
>>>  A.U.S. Enrique Ferreyra
>>>    Centro de Cómputos
>>> Red Megatone - Red Confina
>>>      
>>>
>
>  
>

-- 
  A.U.S. Enrique Ferreyra
    Centro de Cómputos
 Red Megatone - Red Confina


Mime
View raw message