Example #1
0
 public static object UpdateGroup(Guid id, string name, List <string> words)
 {
     return(ServiceAccessor.MakeRequest <GroupUpdateRequest, GroupUpdateResponse>(new GroupUpdateRequest()
     {
         Id = id, Name = name, Words = words
     }, "GroupUpdate").Success);
 }
Example #2
0
 public static object DeleteGroup(Guid id)
 {
     return(ServiceAccessor.MakeRequest <GroupDeleteRequest, GroupDeleteResponse>(new GroupDeleteRequest()
     {
         Id = id
     }, "GroupDelete").Success);
 }
Example #3
0
 public static List <string> Words(Guid id)
 {
     return(ServiceAccessor.MakeRequest <GroupWordsRequest, GroupWordsResponse>(new GroupWordsRequest()
     {
         Id = id
     }, "GroupWords").Words.Select(w => w.Item2).ToList());
 }
Example #4
0
 public static object DeletePhrase(Guid id)
 {
     return(ServiceAccessor.MakeRequest <PhraseDeleteRequest, PhraseDeleteResponse>(new PhraseDeleteRequest()
     {
         Id = id
     }, "PhraseDelete"));
 }
Example #5
0
 public static object GetSongLyrics(Guid songId)
 {
     return(ServiceAccessor.MakeRequest <SongLyricsRequest, SongLyricsResponse>(new SongLyricsRequest()
     {
         SongId = songId
     }, "SongLyrics").SongLyrics);
 }
Example #6
0
 public static object GetGroupWords(Guid groupId)
 {
     return(ServiceAccessor.MakeRequest <GroupWordsRequest, GroupWordsResponse>(new GroupWordsRequest()
     {
         Id = groupId
     }, "GroupWords").Words);
 }
Example #7
0
 public static object GetSongWords(Guid?songId)
 {
     return(ServiceAccessor.MakeRequest <GetWordsRequest, GetWordsResponse>(new GetWordsRequest()
     {
         SongId = songId
     }, "GetWords").Words);
 }
Example #8
0
 public static object AddRelation(Guid type, Guid word1, Guid word2)
 {
     return(ServiceAccessor.MakeRequest <RelationAddRequest, RelationAddResponse>(new RelationAddRequest()
     {
         RelationType = type, Word1 = word1, Word2 = word2
     }, "RelationAdd").Id);
 }
Example #9
0
 public static object RelationTypeDelete(Guid id)
 {
     return(ServiceAccessor.MakeRequest <RelationTypeDeleteRequest, RelationTypeDeleteResponse>(new RelationTypeDeleteRequest()
     {
         TypeId = id
     }, "RelationTypeDelete").Success);
 }
Example #10
0
 public static object AddGroup(string name, List <string> words)
 {
     return(ServiceAccessor.MakeRequest <GroupAddRequest, GroupAddResponse>(new GroupAddRequest()
     {
         Name = name, Words = words
     }, "GroupAdd").Id);
 }
Example #11
0
 public static object AddRelationType(string name)
 {
     return(ServiceAccessor.MakeRequest <RelationAddTypeRequest, RelationAddTypeResponse>(new RelationAddTypeRequest()
     {
         Name = name
     }, "RelationAddType").TypeId);
 }
Example #12
0
 public static object AddPhrase(string phrase)
 {
     return(ServiceAccessor.MakeRequest <PhraseAddRequest, PhraseAddResponse>(new PhraseAddRequest()
     {
         Words = phrase.Split(' ').ToList()
     }, "PhraseAdd"));
 }
Example #13
0
 public static object GetPhraseLocs(string phrase)
 {
     return(ServiceAccessor.MakeRequest <PhraseLocationRequest, PhraseLocationResponse>(new PhraseLocationRequest()
     {
         Phrase = phrase
     }, "PhraseLocations").Locations);
 }
Example #14
0
 public static object GetSongs(string partSongName, string partAritstName)
 {
     return(ServiceAccessor.MakeRequest <SongsRequest, SongsResponse>(new SongsRequest()
     {
         PartSongName = partSongName, PartArtistName = partAritstName
     }, "Songs").Songs);
 }
Example #15
0
 protected void Page_Load(object sender, EventArgs e)
 {
     songs = ServiceAccessor.MakeRequest <SongsRequest, SongsResponse>(new SongsRequest()
     {
         PartSongName = "", PartArtistName = ""
     }, "Songs");
 }
Example #16
0
 public static object GetWordSongs(Guid wordId)
 {
     return(ServiceAccessor.MakeRequest <WordSongsRequest, WordSongsResponse>(new WordSongsRequest()
     {
         WordId = wordId
     }, "WordSongs").WordSongs);
 }
Example #17
0
 public static int RelationTypeUseCount(Guid id)
 {
     return(ServiceAccessor.MakeRequest <RelationTypeUseCountRequest, RelationTypeUseCountResponse>(new RelationTypeUseCountRequest()
     {
         TypeId = id
     }, "RelationTypeUseCount").Count);
 }
Example #18
0
 public static object GetLocations(Guid?songId)
 {
     return(ServiceAccessor.MakeRequest <LocationsRequest,
                                         LocationsResponse>(new LocationsRequest()
     {
         SongId = songId
     }, "Locations").Locations);
 }
Example #19
0
 public static object GetWordByLocation(Guid songId, int numInSong, int verseNum, int lineInVerse)
 {
     return(ServiceAccessor.MakeRequest <WordLocationRequest, LocationsResponse>(
                new WordLocationRequest()
     {
         SongId = songId,
         NumInSong = numInSong,
         VerseNum = verseNum,
         LineInVerse = lineInVerse
     },
                "WordByLocation").Locations);
 }
Example #20
0
 protected void Page_Load(object sender, EventArgs e)
 {
     relations = ServiceAccessor.MakeRequest <RelationAllRequest, RelationAllResponse>(new RelationAllRequest(), "RelationAll");
     relTypes  = ServiceAccessor.MakeRequest <RelationTypesRequest, RelationTypesResponse>(new RelationTypesRequest(), "RelationTypes");
     words     = ServiceAccessor.MakeRequest <GetWordsRequest, GetWordsResponse>(new GetWordsRequest(), "GetWords");
 }
Example #21
0
 protected void Page_Load(object sender, EventArgs e)
 {
     phrases = ServiceAccessor.MakeRequest <PhraseAllRequest, PhraseAllResponse>(new PhraseAllRequest(), "PhraseAll");
 }
Example #22
0
 protected void Page_Load(object sender, EventArgs e)
 {
     stat = ServiceAccessor.MakeRequest <GetStatsRequest, GetStatsResponse>(new GetStatsRequest(), "GetStats");
 }
Example #23
0
 protected void Page_Load(object sender, EventArgs e)
 {
     songs  = ServiceAccessor.MakeRequest <SongsRequest, SongsResponse>(new SongsRequest(), "Songs");
     groups = ServiceAccessor.MakeRequest <GroupAllRequest, GroupAllResponse>(new GroupAllRequest(), "GroupAll");
 }
Example #24
0
 protected void Page_Load(object sender, EventArgs e)
 {
     types = ServiceAccessor.MakeRequest <RelationTypesRequest, RelationTypesResponse>(new RelationTypesRequest(), "RelationTypes");
 }
Example #25
0
 protected void Page_Load(object sender, EventArgs e)
 {
     groups = ServiceAccessor.MakeRequest <GroupAllRequest, GroupAllResponse>(new GroupAllRequest(), "GroupAll");
     words  = ServiceAccessor.MakeRequest <GetWordsRequest, GetWordsResponse>(new GetWordsRequest(), "GetWords");
 }