Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class Media {
- public int id {get;set;}
- public string mediatype {get;set;}
- }
- class Song : Media {
- public string album {get;set;}
- }
- class Movie : Media {
- public string name {get;set;}
- }
- create type AllMedia as table
- (
- id int,
- mediatype nvarchar(50),
- album nvarchar(50),
- name nvarchar(50)
- )
- class MediaTable{
- public int id {get;set;}
- public string mediatype {get;set;}
- public string album {get;set;}
- public string name {get;set;}
- public static List<MediaTable> ToMediaTable<T>(List<T> media){
- ...
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement