Question

I'm taking the lines of code for my Java project , the project contains lot of XML files too. Now my question is when calculating lines of code. Do i need to consider XML lines of code as well? Please help

Was it helpful?

Solution

IMO counting lines of code is a terrible quality metric. I consider it a great day when I remove hundreds of lines of code.

However answering your question. if your XML is handwritten and represents metadata that configures your application then yes I'd consider it to be code.

OTHER TIPS

It depends if the xml is representing data or if it is a DSL of some sort.

If it is just data then I'd ignore it from a LOC metric. However, if it is something like a NAnt script which is essentially programming in xml then I would be tempted to count it as LOC.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top