using System.Xml.Linq;

namespace CoverageFramework.Operator.Generator.Java
{
	public class StatementCoverageGeneratorForJava : ITaggedXElementGenerator
	{
		#region ITaggedXElementGenerator メンバ

		public XElement[] Generate(string tag)
		{
			return new[] {
				new XElement("AExpressionStatement",
					new XElement("ASimpleMethodInvocation",
						new XElement("TIdentifier", "CovMan"),
						new XElement("AAdditionalIdentifier",
							new XElement("TDot", "."),
							new XElement("TIdentifier", "statement")),
						new XElement("TLPar", "("),
						new XElement("AStringLiteral",
							new XElement("TStringLiteral", '"' + tag + '"')),
						new XElement("TRPar", ")")),
					new XElement("TSemi", ";"))
			};
		}

		#endregion
	}
}