Last active
August 6, 2017 18:09
-
-
Save DevEarley/a5e71f6ab660697bc48abe39c8776a6c to your computer and use it in GitHub Desktop.
nancy binding for some app
This file contains hidden or 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
public class ItemModule : NancyModule | |
{ | |
public ItemModule() : base("/items") | |
{ | |
Get("/", p => GetAllItems(this.Bind<ItemRequestModel>())); | |
Get("/{ItemID}", p => GetItem(this.Bind<ItemRequestModel>())); | |
} | |
public List<ItemResponseModel> GetAllItems(ItemRequestModel _ItemRequestModel) | |
{ | |
return new List<ItemResponseModel>(); | |
} | |
public List<ItemResponseModel> GetItem(ItemRequestModel _ItemRequestModel) | |
{ | |
return new List<ItemResponseModel>(); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment