Skip to content
This repository has been archived by the owner on Aug 7, 2021. It is now read-only.

Commit

Permalink
Merge pull request #7 from xhsun/feat/achievements
Browse files Browse the repository at this point in the history
Feat/AchievementsToCharacter
  • Loading branch information
xhsun authored Jun 8, 2017
2 parents 9302d18 + 8f33fd4 commit 39806d6
Show file tree
Hide file tree
Showing 51 changed files with 1,898 additions and 387 deletions.
2 changes: 1 addition & 1 deletion comm.properties
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
currentVer=0.4.3
currentVer=0.5.1
verDesc=Release All Account Endpoints
groupID=me.xhsun.gw2wrapper
projectName=gw2wrapper
Expand Down
320 changes: 312 additions & 8 deletions src/main/java/me/xhsun/guildwars2wrapper/AsynchronousRequest.java

Large diffs are not rendered by default.

2 changes: 2 additions & 0 deletions src/main/java/me/xhsun/guildwars2wrapper/GuildWars2.java
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@
*  2) use methods provided by {@link AsynchronousRequest} to get/process data asynchronously
* TODO chatLinkToItemID
* TODO language selection, default english
* TODO method to resolve back story question using answer id
* TODO coins to gold/sliver/copper
* @author xhsun
* @since 2017-02-06
*/
Expand Down
74 changes: 72 additions & 2 deletions src/main/java/me/xhsun/guildwars2wrapper/GuildWars2API.java
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,13 @@
import me.xhsun.guildwars2wrapper.model.*;
import me.xhsun.guildwars2wrapper.model.account.*;
import me.xhsun.guildwars2wrapper.model.achievements.Achievement;
import me.xhsun.guildwars2wrapper.model.character.CharacterInventory;
import me.xhsun.guildwars2wrapper.model.character.Core;
import me.xhsun.guildwars2wrapper.model.achievements.AchievementCategory;
import me.xhsun.guildwars2wrapper.model.achievements.AchievementGroup;
import me.xhsun.guildwars2wrapper.model.achievements.DailyAchievement;
import me.xhsun.guildwars2wrapper.model.backstory.BackStoryAnswer;
import me.xhsun.guildwars2wrapper.model.backstory.BackStoryQuestion;
import me.xhsun.guildwars2wrapper.model.character.Character;
import me.xhsun.guildwars2wrapper.model.character.*;
import me.xhsun.guildwars2wrapper.model.commerce.Prices;
import me.xhsun.guildwars2wrapper.model.commerce.Transaction;
import me.xhsun.guildwars2wrapper.model.guild.Upgrade;
Expand Down Expand Up @@ -102,16 +107,81 @@ interface GuildWars2API {
@GET("/v2/achievements")
Call<List<Achievement>> getAchievementInfo(@Query("ids") String ids);

@GET("/v2/achievements/categories")
Call<List<Integer>> getAllAchievementCategoryIDs();

@GET("/v2/achievements/categories")
Call<List<AchievementCategory>> getAchievementCategoryInfo(@Query("ids") String ids);

@GET("/v2/achievements/daily")
Call<DailyAchievement> getCurrentDailyAchievements();

@GET("/v2/achievements/daily/tomorrow")
Call<DailyAchievement> getNextDailyAchievements();

@GET("/v2/achievements/groups")
Call<List<String>> getAllAchievementGroupIDs();

@GET("/v2/achievements/groups")
Call<List<AchievementGroup>> getAchievementGroupInfo(@Query("ids") String ids);

//back story
@GET("/v2/backstory/answers")
Call<List<String>> getAllBackStoryAnswerIDs();

@GET("/v2/backstory/answers")
Call<List<BackStoryAnswer>> getBackStoryAnswerInfo(@Query("ids") String ids);

@GET("/v2/backstory/questions")
Call<List<Integer>> getAllBackStoryQuestionIDs();

@GET("/v2/backstory/questions")
Call<List<BackStoryQuestion>> getBackStoryQuestionInfo(@Query("ids") String ids);

//Current Game Build
@GET("/v2/build")
Call<GameBuild> getCurrentGameBuild();

//characters
@GET("/v2/characters")
Call<List<String>> getAllCharacterName(@Query("access_token") String token);

@GET("/v2/characters/{name}")
Call<Character> getCharacter(@Path("name") String name, @Query("access_token") String token);

@GET("/v2/characters/{name}/backstory")
Call<CharacterBackStory> getCharacterBackStory(@Path("name") String name, @Query("access_token") String token);

@GET("/v2/characters/{name}/core")
Call<Core> getCharacterCore(@Path("name") String name, @Query("access_token") String token);

@GET("/v2/characters/{name}/crafting")
Call<CraftingLevel> getCharacterCrafting(@Path("name") String name, @Query("access_token") String token);

@GET("/v2/characters/{name}/equipment")
Call<CharacterEquipment> getCharacterEquipment(@Path("name") String name, @Query("access_token") String token);

@GET("/v2/characters/{name}/heropoints")
Call<List<String>> getCharacterHeroPoints(@Path("name") String name, @Query("access_token") String token);

@GET("/v2/characters/{name}/inventory")
Call<CharacterInventory> getCharacterInventory(@Path("name") String name, @Query("access_token") String token);

@GET("/v2/characters/{name}/recipes")
Call<CharacterRecipes> getCharacterUnlockedRecipes(@Path("name") String name, @Query("access_token") String token);

@GET("/v2/characters/{name}/sab")
Call<CharacterSAB> getCharacterSAB(@Path("name") String name, @Query("access_token") String token);

@GET("/v2/characters/{name}/skills")
Call<CharacterSkills> getCharacterSkills(@Path("name") String name, @Query("access_token") String token);

@GET("/v2/characters/{name}/specializations")
Call<CharacterSpecialization> getCharacterSpecialization(@Path("name") String name, @Query("access_token") String token);

@GET("/v2/characters/{name}/training")
Call<CharacterTraining> getCharacterTraining(@Path("name") String name, @Query("access_token") String token);

//colors
@GET("/v2/colors")
Call<List<Integer>> getAllColorIDs();
Expand Down
Loading

0 comments on commit 39806d6

Please sign in to comment.