Column identifier is reserved word - workaround, or private properties?

Jan 13, 2011 at 9:12 PM

Hi guys,

I've only been trying out nHydrate for a few days and I really like it.

I have an issue though where I want to extend the persitable object with another interface.  The interface is third-party so I cannot change the spec, and one of the properties is named End.  When I try to add that to my nHydrate model, it flags an error and says that it's a reserved word.

If there's no way around a reserved word, is there a way to create a persitable property but mark it as private, so I can internally map the interface property?  Otherwise I end up with an object that has two public properties that do the same thing, and that just doesn't feel right :)

 

Thanks guys for an awesome product!

Adam.

Coordinator
Jan 13, 2011 at 11:15 PM

We have removed some of the VB.NET ones as they are not needed for generated C# code. We have removed "Each,Else,ElseIf,End,Goto,MustInherit,MustOverride,MyBase,MyClass,NotInheritable,NotOverridable,Overloads,Overridable,Overrides,ParamArray".

Look for this in the next version. It will be this weekend or early next week.

Jan 14, 2011 at 7:50 AM

Thanks for the quick reply, I shall be looking out for the release.

On the private property thing, is it at all possible, perhaps with extending the generator?

I ask because with this interface I need to implement, there is another property of type TimeZoneInfo.  Now I can't create a property in the nHydrate model with that type, so one method to me would be to create a private property where the TimeZoneInfo can be serialised into and persisted to the database, but leave the public TimeZoneInfo property for outside use.

Any thoughts?

Thanks again.

Adam.