I was not subscribed to this list. Thanks for pointing it out Ron. I'm
emailing here first before opening a Jira issue. LMK if should just
go to Jira first in the future.
I just downloaded and attempted to use 1.1.0.458.
IBatisNet.DataMapper.SqlMapper still does not support a non project
relative filename.
I create separate Mapper singletons for each of my databases used in
my DAL. I then make a call like:
_mapper = SqlMapper.ConfigureAndWatch(@"c:/Web Services/DB
Configuration/Transmission/TransmissionMap.config", handler);
ConfigurateAndWatch calls
IBatisNet.Common.Utilities.Resources.GetConfigAsXmlDocument() which
assumes a project relative filename.
My previous version hack looks like:
public static XmlDocument GetConfigAsXmlDocument(string
fileName)
{
XmlDocument config = new XmlDocument();
try
{
XmlTextReader reader;
if ((fileName[1] == ':' && fileName[2] == '\\')
|| fileName[0] == '\\' ||
fileName.ToLower().Substring(0, 7) ==
"file://")
{ // detects paths starting with drive:, \, \\
reader = new XmlTextReader(fileName);
}
else
{
reader = new
XmlTextReader(_baseDirectory +
Path.DirectorySeparatorChar + fileName);
}
config.Load(reader);
reader.Close();
}
catch(Exception e)
{
throw new ConfigurationException(
string.Format("Unable to load config
file \"{0}\". Cause : ",
fileName,
e.Message ) ,e);
}
return config;
}