Concise C# Property Name

When constructing XML elements, it’s nice to have a concise API.

One of the features I’m implementing is the ability to easily move up to a parent element. There’s no cascade operator in C#, like you see in Dart.

Whilst exploring options, I found this works:

Example usage:

var e = new BvElement("iq");

I thought that was interesting – albeit obvious when you think about it 🙂

But on a serious note, looking for something suitable, appreciate suggestions.


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s