static void Main(string[] args) { Type t = typeof(Sailboat); AuthorAttributeCheck check = new AuthorAttributeCheck(t); string name = check.GetAuthorName(); if(name != null) Console.WriteLine("The author's name is: {0}", name); name = check.GetAuthorName(); if(name != null) Console.WriteLine("The author's name is: {0}", name); string notes = check.GetNotes(); if(notes != null) Console.WriteLine("The author's notes are: {0}", notes); string[] authorInfo = check.GetAllMemberAuthorInfo(); foreach(string authorName in authorInfo) { Console.WriteLine(authorName); } string[] authorInfo2 = check.GetMemberAuthorInfo("Text"); foreach(string authorName in authorInfo2) { Console.WriteLine(authorName); } name = check.GetAssemblyAuthorName("Authoring"); Console.WriteLine("Assembly author attribute: {0}", name); Console.WriteLine("done"); }
static void Main(string[] args) { Type t = typeof(Sailboat); AuthorAttributeCheck check = new AuthorAttributeCheck(t); string name = check.GetAuthorName(); if (name != null) { Console.WriteLine("The author's name is: {0}", name); } name = check.GetAuthorName(); if (name != null) { Console.WriteLine("The author's name is: {0}", name); } string notes = check.GetNotes(); if (notes != null) { Console.WriteLine("The author's notes are: {0}", notes); } string[] authorInfo = check.GetAllMemberAuthorInfo(); foreach (string authorName in authorInfo) { Console.WriteLine(authorName); } string[] authorInfo2 = check.GetMemberAuthorInfo("Text"); foreach (string authorName in authorInfo2) { Console.WriteLine(authorName); } name = check.GetAssemblyAuthorName("Authoring"); Console.WriteLine("Assembly author attribute: {0}", name); Console.WriteLine("done"); }