ralphtrent
Programmer
Hello
I have the following code
this code is exposed over a WCF.
when I refer to this service in another project I do not see the Microsoft.Practices.EnterpriseLibrary.Logging.LogEntry properties like Message, Title...
instead I am seeing message, title (notice the case difference) and I get a ton more properties then what is exposed in Microsoft.Practices.EnterpriseLibrary.Logging.LogEntry. I only get to see the properties i expect to see when I include a reference to Microsoft.Practices.EnterpriseLibrary.Logging.LogEntry in my calling project.
Is that an expected behavoir since I am not providing any properties in my derived class?
meaning should my first code block look like this:
I have the following code
Code:
public class LoggedEvent : Microsoft.Practices.EnterpriseLibrary.Logging.LogEntry
{
}
this code is exposed over a WCF.
Code:
public void LogEvent(LoggedEvent loggedEvent)
{
el.LogWriter elw = EnterpriseLibraryContainer.Current.GetInstance<el.LogWriter>();
try
{
elw.Write(loggedEvent);
}
catch
{
throw;
}
}
when I refer to this service in another project I do not see the Microsoft.Practices.EnterpriseLibrary.Logging.LogEntry properties like Message, Title...
instead I am seeing message, title (notice the case difference) and I get a ton more properties then what is exposed in Microsoft.Practices.EnterpriseLibrary.Logging.LogEntry. I only get to see the properties i expect to see when I include a reference to Microsoft.Practices.EnterpriseLibrary.Logging.LogEntry in my calling project.
Is that an expected behavoir since I am not providing any properties in my derived class?
meaning should my first code block look like this:
Code:
public class LoggedEvent : Microsoft.Practices.EnterpriseLibrary.Logging.LogEntry
{
new string Message { get { return base.Message; } set { base.Message = value; } }
new string Title { get { return base.Title ; } set { base.Title = value; } }
}