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

Complete fix for using long data type for all identifiers #38

Open
wants to merge 7 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion .idea/.name

This file was deleted.

Binary file removed .idea/caches/build_file_checksums.ser
Binary file not shown.
29 changes: 0 additions & 29 deletions .idea/codeStyles/Project.xml

This file was deleted.

3 changes: 3 additions & 0 deletions .idea/gradle.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions .idea/modules.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,5 +25,6 @@ before_install:
- echo "sdk.dir=$ANDROID_HOME" > local.properties
- echo "bintray.user=user" >> local.properties
- echo "bintray.apikey=key" >> local.properties
- yes | sdkmanager "platforms;android-27"
script:
- ./gradlew clean assemble test
Original file line number Diff line number Diff line change
Expand Up @@ -23,15 +23,15 @@ public CreateActivityRequest createActivity(String name) {
return new CreateActivityRequest(name, getAPI(ActivityRest.class), this);
}

public GetActivityRequest getActivity(int activityID) {
public GetActivityRequest getActivity(long activityID) {
return new GetActivityRequest(activityID, getAPI(ActivityRest.class), this);
}

public UpdateActivityRequest updateActivity(int activityID) {
public UpdateActivityRequest updateActivity(long activityID) {
return new UpdateActivityRequest(activityID, getAPI(ActivityRest.class), this);
}

public DeleteActivityRequest deleteActivity(int activityID) {
public DeleteActivityRequest deleteActivity(long activityID) {
return new DeleteActivityRequest(activityID, getAPI(ActivityRest.class), this);
}

Expand All @@ -43,15 +43,15 @@ public ListFriendActivitiesRequest listFriendActivities() {
return new ListFriendActivitiesRequest(getAPI(ActivityRest.class), this);
}

public ListRelatedActivitiesRequest listRelatedActivities(int activityID) {
public ListRelatedActivitiesRequest listRelatedActivities(long activityID) {
return new ListRelatedActivitiesRequest(activityID, getAPI(ActivityRest.class), this);
}

public ListActivityZonesRequest listActivityZones(int activityID) {
public ListActivityZonesRequest listActivityZones(long activityID) {
return new ListActivityZonesRequest(activityID, getAPI(ActivityRest.class), this);
}

public ListActivityLapsRequest listActivityLaps(int activityID) {
public ListActivityLapsRequest listActivityLaps(long activityID) {
return new ListActivityLapsRequest(activityID, getAPI(ActivityRest.class), this);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ public CommentAPI(StravaConfig config) {
super(config);
}

public ListActivityCommentsRequest listActivityComments(int activityID) {
public ListActivityCommentsRequest listActivityComments(long activityID) {
return new ListActivityCommentsRequest(activityID, getAPI(CommentsRest.class), this);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ public KudosAPI(StravaConfig config) {
super(config);
}

public ListActivityKudoersRequest listActivityKudoers(int activityID) {
public ListActivityKudoersRequest listActivityKudoers(long activityID) {
return new ListActivityKudoersRequest(activityID, getAPI(KudosRest.class), this);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ public PhotoAPI(StravaConfig config) {
super(config);
}

public ListActivityPhotosRequest listAcivityPhotos(int activityID) {
public ListActivityPhotosRequest listAcivityPhotos(long activityID) {
return new ListActivityPhotosRequest(activityID, getAPI(PhotosRest.class), this);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,10 @@
import java.util.List;

public class Activity {
@SerializedName("id") private int ID;
@SerializedName("id") private long ID;
@SerializedName("resource_state") private ResourceState resourceState;
@SerializedName("external_id") private String externalID;
@SerializedName("upload_id") private int uploadID;
@SerializedName("upload_id") private long uploadID;
@SerializedName("athlete") private Athlete athlete;
@SerializedName("name") private String name;
@SerializedName("description") private String description;
Expand Down Expand Up @@ -73,7 +73,7 @@ public class Activity {
@SerializedName("splits_metric") private List<Split> splitsMetric;
@SerializedName("splits_standard") private List<Split> splitsStandard;

public int getID() {
public long getID() {
return ID;
}

Expand All @@ -85,7 +85,7 @@ public String getExternalID() {
return externalID;
}

public int getUploadID() {
public long getUploadID() {
return uploadID;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
import java.util.Date;

public class ActivityLap {
@SerializedName("id") private int ID;
@SerializedName("id") private long ID;
@SerializedName("resource_state") private ResourceState resourceState;
@SerializedName("name") private String name;
@SerializedName("activity") private Activity activity;
Expand All @@ -33,7 +33,7 @@ public class ActivityLap {
@SerializedName("average_heartrate") private float averageHeartRate;
@SerializedName("lap_index") private int lapIndex;

public int getID() {
public long getID() {
return ID;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,22 +7,22 @@
import java.util.Date;

public class Comment {
@SerializedName("id") private int ID;
@SerializedName("id") private long ID;
@SerializedName("resource_state") private ResourceState resourceState;
@SerializedName("activity_id") private int activityID;
@SerializedName("activity_id") private long activityID;
@SerializedName("text") private String text;
@SerializedName("athlete") private Athlete athlete;
@SerializedName("created_at") private Date createdAt;

public int getID() {
public long getID() {
return ID;
}

public ResourceState getResourceState() {
return resourceState;
}

public int getActivityID() {
public long getActivityID() {
return activityID;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@

public class Photo {
@SerializedName("unique_id") private String uniqueID;
@SerializedName("id") private int ID;
@SerializedName("activity_id") private int activityID;
@SerializedName("id") private long ID;
@SerializedName("activity_id") private long activityID;
@SerializedName("resource_state") private ResourceState resourceState;
@SerializedName("urls") private HashMap<String, String> urls;
@SerializedName("caption") private String caption;
Expand All @@ -26,11 +26,11 @@ public String getUniqueID() {
return uniqueID;
}

public int getID() {
public long getID() {
return ID;
}

public int getActivityID() {
public long getActivityID() {
return activityID;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@
import java.util.HashMap;

public class PrimaryPhoto {
@SerializedName("id") private int ID;
@SerializedName("id") private long ID;
@SerializedName("source") private PhotoSource source;
@SerializedName("unique_id") private String uniqueID;
@SerializedName("urls") private HashMap<String, String> urls;

public int getID() {
public long getID() {
return ID;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@

public class DeleteActivityRequest {

private final int activityID;
private final long activityID;
private final ActivityRest restService;
private final ActivityAPI api;

public DeleteActivityRequest(int activityID, ActivityRest restService, ActivityAPI api) {
public DeleteActivityRequest(long activityID, ActivityRest restService, ActivityAPI api) {
this.activityID = activityID;
this.restService = restService;
this.api = api;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,12 @@

public class GetActivityRequest {

private final int activityID;
private final long activityID;
private final ActivityRest restService;
private final ActivityAPI api;
private Boolean includeAllEfforts;

public GetActivityRequest(int activityID, ActivityRest restService, ActivityAPI api) {
public GetActivityRequest(long activityID, ActivityRest restService, ActivityAPI api) {
this.activityID = activityID;
this.restService = restService;
this.api = api;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,13 @@

public class ListActivityCommentsRequest {

private final int activityID;
private final long activityID;
private final CommentsRest restService;
private final CommentAPI api;
private Integer page;
private Integer perPage;

public ListActivityCommentsRequest(int activityID, CommentsRest restService, CommentAPI api) {
public ListActivityCommentsRequest(long activityID, CommentsRest restService, CommentAPI api) {
this.activityID = activityID;
this.restService = restService;
this.api = api;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,13 @@

public class ListActivityKudoersRequest {

private final int activityID;
private final long activityID;
private final KudosRest restService;
private final KudosAPI api;
private Integer page;
private Integer perPage;

public ListActivityKudoersRequest(int activityID, KudosRest restService, KudosAPI api) {
public ListActivityKudoersRequest(long activityID, KudosRest restService, KudosAPI api) {
this.activityID = activityID;
this.restService = restService;
this.api = api;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,11 @@

public class ListActivityLapsRequest {

private final int activityID;
private final long activityID;
private final ActivityRest restService;
private final ActivityAPI api;

public ListActivityLapsRequest(int activityID, ActivityRest restService, ActivityAPI api) {
public ListActivityLapsRequest(long activityID, ActivityRest restService, ActivityAPI api) {
this.activityID = activityID;
this.restService = restService;
this.api = api;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,11 @@

public class ListActivityPhotosRequest {

private final int activityID;
private final long activityID;
private final PhotosRest restService;
private final PhotoAPI api;

public ListActivityPhotosRequest(int activityID, PhotosRest restService, PhotoAPI api) {
public ListActivityPhotosRequest(long activityID, PhotosRest restService, PhotoAPI api) {
this.activityID = activityID;
this.restService = restService;
this.api = api;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,11 @@

public class ListActivityZonesRequest {

private final int activityID;
private final long activityID;
private final ActivityRest restService;
private final ActivityAPI api;

public ListActivityZonesRequest(int activityID, ActivityRest restService, ActivityAPI api) {
public ListActivityZonesRequest(long activityID, ActivityRest restService, ActivityAPI api) {
this.activityID = activityID;
this.restService = restService;
this.api = api;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,13 @@

public class ListRelatedActivitiesRequest {

private final int activityID;
private final long activityID;
private final ActivityRest restService;
private final ActivityAPI api;
private Integer page;
private Integer perPage;

public ListRelatedActivitiesRequest(int activityID, ActivityRest restService, ActivityAPI api) {
public ListRelatedActivitiesRequest(long activityID, ActivityRest restService, ActivityAPI api) {
this.activityID = activityID;
this.restService = restService;
this.api = api;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

public class UpdateActivityRequest {

private final int activityID;
private final long activityID;
private final ActivityRest restService;
private final ActivityAPI api;
private String name;
Expand All @@ -20,7 +20,7 @@ public class UpdateActivityRequest {
private String gearID;
private String description;

public UpdateActivityRequest(int activityID, ActivityRest restService, ActivityAPI api) {
public UpdateActivityRequest(long activityID, ActivityRest restService, ActivityAPI api) {
this.activityID = activityID;
this.restService = restService;
this.api = api;
Expand Down
Loading