| @@ -0,0 +1,12 @@ | |||||
| package xyz.veronie.bgg.result; | |||||
| /// Holds an id and its string representation, for example for Family, Extension, Mechanic, or Category. | |||||
| public class IdString { | |||||
| int id; | |||||
| String string; | |||||
| public IdString(int id, String string) { | |||||
| this.id = id; | |||||
| this.string = string; | |||||
| } | |||||
| } | |||||
| @@ -1,8 +1,9 @@ | |||||
| package xyz.veronie.bgg.result; | package xyz.veronie.bgg.result; | ||||
| public enum Recommendation { | public enum Recommendation { | ||||
| N, // not supported | |||||
| P, // not recommended | |||||
| R, // recommended | |||||
| B // best | |||||
| N, // (N)onplayable | |||||
| P, // (P)layable, not recommended | |||||
| R, // (R)ecommended | |||||
| B // (B)est with... | |||||
| } | } | ||||
| @@ -164,6 +164,7 @@ public class Thing { | |||||
| * | * | ||||
| * @return | * @return | ||||
| */ | */ | ||||
| // TODO: rewrite: order isn't important, column names are | |||||
| public String toResultTxtLine() { | public String toResultTxtLine() { | ||||
| StringBuilder str = new StringBuilder(); | StringBuilder str = new StringBuilder(); | ||||
| final String emptyItem = "\"\","; | final String emptyItem = "\"\","; | ||||
| @@ -23,12 +23,12 @@ public class ThingDetails { | |||||
| Float stddev; | Float stddev; | ||||
| Float median; | Float median; | ||||
| String image; | String image; | ||||
| Integer category; | |||||
| Integer mechanic; | |||||
| IdString[] category; | |||||
| IdString[] mechanic; | |||||
| String comment; | String comment; | ||||
| Recommendation[] players; // 1 to 20 | Recommendation[] players; // 1 to 20 | ||||
| String description; | String description; | ||||
| Integer expansion; | |||||
| IdString[] expansion; | |||||
| Integer basegameId; | Integer basegameId; | ||||
| Integer reimplementId; | Integer reimplementId; | ||||
| String reimplement_name; | String reimplement_name; | ||||
| @@ -44,6 +44,6 @@ public class ThingDetails { | |||||
| Float price; | Float price; | ||||
| Integer expansions; | Integer expansions; | ||||
| String domain; | String domain; | ||||
| String family; | |||||
| IdString[] family; | |||||
| Float age_poll; | Float age_poll; | ||||
| } | } | ||||