Last active
November 16, 2017 03:09
-
-
Save jglozano/a1a37c423c4b8c056eeda347d178ac01 to your computer and use it in GitHub Desktop.
.NET Development YTT Demo - code for interface, service, and viewmodel
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Interface | |
public interface IPersonService | |
{ | |
PersonViewModel[] GetRetiredPeople(string dataPath); | |
} | |
// Implementation | |
public class PersonService : IPersonService | |
{ | |
public PersonViewModel[] GetRetiredPeople(string dataPath) | |
{ | |
return new[] { new PersonViewModel { FullName = "Test Person" } }; | |
} | |
} | |
//ViewModel | |
public class PersonViewModel | |
{ | |
public string FullName { get; set; } | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment