Quantcast
Viewing all articles
Browse latest Browse all 3509

How does ASP .NET decide what duplicate elements to rename in reference.cs file

Hello

I regularly work on schema maintenance projects for services that our MVC applications consume. I use VS2017 to open a solution and configure/update service references. The end result that I'm interested in is the recreation of the reference.cs file for each service reference refreshed (because it's schema has changed).

What I observe and it may be triggered by poor schema design, is that some services contain duplicate element names identifiable or separated only by their source .xsd. During the creation of the reference.cs file, .NET will rename duplicate element names by simply adding a number/index to the name.

Example:

CustomerType, CustomerType1, CustomerType2

What I need to understand is how .NET determines which duplicate element name gets "renamed". I assume there is some ordering scheme that is followed.

Any help would be much appreciated.

Thanks in advance.

Viewing all articles
Browse latest Browse all 3509

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>