Skip to content

Commit

Permalink
Merge pull request #5 from Alex1304/id-change
Browse files Browse the repository at this point in the history
Package ID changed to com.github.alex1304
  • Loading branch information
Alex1304 committed May 10, 2018
2 parents d4d1368 + c3de70c commit cc2e8b9
Show file tree
Hide file tree
Showing 32 changed files with 133 additions and 128 deletions.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,10 @@ Download the latest version at the [releases](https://github.com/Alex1304/jdash/
Here is a quick example of the usage of the library:

```Java
import com.alex1304dev.jdash.api.GDHttpClient;
import com.alex1304dev.jdash.api.request.GDLevelHttpRequest;
import com.alex1304dev.jdash.component.GDLevel;
import com.alex1304dev.jdash.exceptions.GDAPIException;
import com.github.alex1304.jdash.api.GDHttpClient;
import com.github.alex1304.jdash.api.request.GDLevelHttpRequest;
import com.github.alex1304.jdash.component.GDLevel;
import com.github.alex1304.jdash.exceptions.GDAPIException;

public class TestMain {

Expand Down
44 changes: 22 additions & 22 deletions docs/3.-The-HTTP-request-objects.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,24 +40,24 @@ GDLevelSearchHttpRequest request = new GDLevelSearchHttpRequest("sonic wave", 0)
**Constructor 2 parameters:**

* type (`int`), the type of search (regular search, featured section, most recent levels). It can be one of the following values:
* `com.alex1304dev.jdash.util.Constants.LEVEL_SEARCH_TYPE_REGULAR`
* `com.alex1304dev.jdash.util.Constants.LEVEL_SEARCH_TYPE_RECENT`
* `com.alex1304dev.jdash.util.Constants.LEVEL_SEARCH_TYPE_TRENDING`
* `com.alex1304dev.jdash.util.Constants.LEVEL_SEARCH_TYPE_MOST_DOWNLOADED`
* `com.alex1304dev.jdash.util.Constants.LEVEL_SEARCH_TYPE_MOST_LIKED`
* `com.alex1304dev.jdash.util.Constants.LEVEL_SEARCH_TYPE_FEATURED`
* `com.alex1304dev.jdash.util.Constants.LEVEL_SEARCH_TYPE_HALL_OF_FAME`
* `com.github.alex1304.jdash.util.Constants.LEVEL_SEARCH_TYPE_REGULAR`
* `com.github.alex1304.jdash.util.Constants.LEVEL_SEARCH_TYPE_RECENT`
* `com.github.alex1304.jdash.util.Constants.LEVEL_SEARCH_TYPE_TRENDING`
* `com.github.alex1304.jdash.util.Constants.LEVEL_SEARCH_TYPE_MOST_DOWNLOADED`
* `com.github.alex1304.jdash.util.Constants.LEVEL_SEARCH_TYPE_MOST_LIKED`
* `com.github.alex1304.jdash.util.Constants.LEVEL_SEARCH_TYPE_FEATURED`
* `com.github.alex1304.jdash.util.Constants.LEVEL_SEARCH_TYPE_HALL_OF_FAME`
* keywords (`String`), the search keywords
* difficulties (`Set<Integer>`), the difficulty filter. Allows multi-selection of filters by giving more than one value in the set. Each item of this set can be one of the following values:
* `com.alex1304dev.jdash.util.Constants.LEVEL_SEARCH_DIFF_ALL`
* `com.alex1304dev.jdash.util.Constants.LEVEL_SEARCH_DIFF_NA`
* `com.alex1304dev.jdash.util.Constants.LEVEL_SEARCH_DIFF_EASY`
* `com.alex1304dev.jdash.util.Constants.LEVEL_SEARCH_DIFF_NORMAL`
* `com.alex1304dev.jdash.util.Constants.LEVEL_SEARCH_DIFF_HARD`
* `com.alex1304dev.jdash.util.Constants.LEVEL_SEARCH_DIFF_HARDER`
* `com.alex1304dev.jdash.util.Constants.LEVEL_SEARCH_DIFF_INSANE`
* `com.alex1304dev.jdash.util.Constants.LEVEL_SEARCH_DIFF_DEMON`
* lengths (`Set<Integer>`), the length filter. Also allows multi-selection. Items can take the values of the ordinal of any item in `com.alex1304dev.jdash.component.property.GDLevelLength`:
* `com.github.alex1304.jdash.util.Constants.LEVEL_SEARCH_DIFF_ALL`
* `com.github.alex1304.jdash.util.Constants.LEVEL_SEARCH_DIFF_NA`
* `com.github.alex1304.jdash.util.Constants.LEVEL_SEARCH_DIFF_EASY`
* `com.github.alex1304.jdash.util.Constants.LEVEL_SEARCH_DIFF_NORMAL`
* `com.github.alex1304.jdash.util.Constants.LEVEL_SEARCH_DIFF_HARD`
* `com.github.alex1304.jdash.util.Constants.LEVEL_SEARCH_DIFF_HARDER`
* `com.github.alex1304.jdash.util.Constants.LEVEL_SEARCH_DIFF_INSANE`
* `com.github.alex1304.jdash.util.Constants.LEVEL_SEARCH_DIFF_DEMON`
* lengths (`Set<Integer>`), the length filter. Also allows multi-selection. Items can take the values of the ordinal of any item in `com.github.alex1304.jdash.component.property.GDLevelLength`:
* page (`int`), the page number of the results, starting at 0
* uncompleted (`boolean`), enables the "uncompleted" filter if set to true. Will request only uncompleted levels. For now this has no effect because this request object doesn't suppot authentication, and this filter would need the client to be authenticated for it to work.
* onlyCompleted (`boolean`), enables the "only completed" filter if set to true. Will request only completed levels. Same note as for uncompleted.
Expand All @@ -68,12 +68,12 @@ GDLevelSearchHttpRequest request = new GDLevelSearchHttpRequest("sonic wave", 0)
* epic (`boolean`), enables the "epic" filter if set to to true. Will request only epic levels.
* star (`boolean`), enables the "star" filter if set to to true. Will request only levels with a star rate.
* demonFilter (`int`), sets a demon filter between the following values:
* `com.alex1304dev.jdash.util.Constants.LEVEL_SEARCH_DIFF_ALL`
* `com.alex1304dev.jdash.util.Constants.LEVEL_SEARCH_DIFF_EASY_DEMON`
* `com.alex1304dev.jdash.util.Constants.LEVEL_SEARCH_DIFF_MEDIUM_DEMON`
* `com.alex1304dev.jdash.util.Constants.LEVEL_SEARCH_DIFF_HARD_DEMON`
* `com.alex1304dev.jdash.util.Constants.LEVEL_SEARCH_DIFF_INSANE_DEMON`
* `com.alex1304dev.jdash.util.Constants.LEVEL_SEARCH_DIFF_EXTREME_DEMON`
* `com.github.alex1304.jdash.util.Constants.LEVEL_SEARCH_DIFF_ALL`
* `com.github.alex1304.jdash.util.Constants.LEVEL_SEARCH_DIFF_EASY_DEMON`
* `com.github.alex1304.jdash.util.Constants.LEVEL_SEARCH_DIFF_MEDIUM_DEMON`
* `com.github.alex1304.jdash.util.Constants.LEVEL_SEARCH_DIFF_HARD_DEMON`
* `com.github.alex1304.jdash.util.Constants.LEVEL_SEARCH_DIFF_INSANE_DEMON`
* `com.github.alex1304.jdash.util.Constants.LEVEL_SEARCH_DIFF_EXTREME_DEMON`

```Java
// This will request all Easy epic levels with coins that match the keywords
Expand Down
8 changes: 6 additions & 2 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,17 @@
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>

<groupId>com.alex1304dev</groupId>
<groupId>com.github.alex1304</groupId>
<artifactId>jdash</artifactId>
<version>1.0.1</version>
<version>2.0.0</version>
<packaging>jar</packaging>

<name>jdash</name>
<url>http://maven.apache.org</url>

<scm>
<url>https://github.com/Alex1304/jdash.git</url>
</scm>

<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.alex1304dev.jdash.api;
package com.github.alex1304.jdash.api;

import java.io.BufferedReader;
import java.io.DataOutputStream;
Expand All @@ -8,9 +8,9 @@
import java.net.URL;
import java.util.Map.Entry;

import com.alex1304dev.jdash.component.GDComponent;
import com.alex1304dev.jdash.exceptions.GDAPIException;
import com.alex1304dev.jdash.util.Constants;
import com.github.alex1304.jdash.component.GDComponent;
import com.github.alex1304.jdash.exceptions.GDAPIException;
import com.github.alex1304.jdash.util.Constants;

/**
* Handles HTTP requests to Geometry Dash servers
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
package com.alex1304dev.jdash.api;
package com.github.alex1304.jdash.api;

import java.util.HashMap;
import java.util.Map;

import com.alex1304dev.jdash.component.GDComponent;
import com.github.alex1304.jdash.component.GDComponent;

/**
* Contains the parameters sent with the POST request to the Geometry Dash
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.alex1304dev.jdash.api;
package com.github.alex1304.jdash.api;

import com.alex1304dev.jdash.component.GDComponent;
import com.github.alex1304.jdash.component.GDComponent;

/**
* Builds a GDHttpResponse object according to the string returned by the server
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
package com.alex1304dev.jdash.api.request;
package com.github.alex1304.jdash.api.request;

import java.util.Base64;
import java.util.Map;

import com.alex1304dev.jdash.api.GDHttpRequest;
import com.alex1304dev.jdash.api.GDHttpResponseBuilder;
import com.alex1304dev.jdash.component.GDLevel;
import com.alex1304dev.jdash.component.property.GDLevelLength;
import com.alex1304dev.jdash.util.Constants;
import com.alex1304dev.jdash.util.Utils;
import com.alex1304dev.jdash.util.robtopsweakcrypto.RobTopsWeakCrypto;
import com.github.alex1304.jdash.api.GDHttpRequest;
import com.github.alex1304.jdash.api.GDHttpResponseBuilder;
import com.github.alex1304.jdash.component.GDLevel;
import com.github.alex1304.jdash.component.property.GDLevelLength;
import com.github.alex1304.jdash.util.Constants;
import com.github.alex1304.jdash.util.Utils;
import com.github.alex1304.jdash.util.robtopsweakcrypto.RobTopsWeakCrypto;

/**
* HTTP Request to fetch a GD level
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.alex1304dev.jdash.api.request;
package com.github.alex1304.jdash.api.request;

import java.io.UnsupportedEncodingException;
import java.net.URLEncoder;
Expand All @@ -7,13 +7,13 @@
import java.util.Map;
import java.util.Set;

import com.alex1304dev.jdash.api.GDHttpRequest;
import com.alex1304dev.jdash.api.GDHttpResponseBuilder;
import com.alex1304dev.jdash.component.GDComponentList;
import com.alex1304dev.jdash.component.GDLevelPreview;
import com.alex1304dev.jdash.component.property.GDLevelLength;
import com.alex1304dev.jdash.util.Constants;
import com.alex1304dev.jdash.util.Utils;
import com.github.alex1304.jdash.api.GDHttpRequest;
import com.github.alex1304.jdash.api.GDHttpResponseBuilder;
import com.github.alex1304.jdash.component.GDComponentList;
import com.github.alex1304.jdash.component.GDLevelPreview;
import com.github.alex1304.jdash.component.property.GDLevelLength;
import com.github.alex1304.jdash.util.Constants;
import com.github.alex1304.jdash.util.Utils;

/**
* HTTP request to search for levels
Expand Down
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
package com.alex1304dev.jdash.api.request;
package com.github.alex1304.jdash.api.request;

import java.util.Base64;
import java.util.Map;

import com.alex1304dev.jdash.api.GDHttpRequest;
import com.alex1304dev.jdash.api.GDHttpResponseBuilder;
import com.alex1304dev.jdash.component.GDComponentList;
import com.alex1304dev.jdash.component.GDMessage;
import com.alex1304dev.jdash.util.Constants;
import com.alex1304dev.jdash.util.Utils;
import com.github.alex1304.jdash.api.GDHttpRequest;
import com.github.alex1304.jdash.api.GDHttpResponseBuilder;
import com.github.alex1304.jdash.component.GDComponentList;
import com.github.alex1304.jdash.component.GDMessage;
import com.github.alex1304.jdash.util.Constants;
import com.github.alex1304.jdash.util.Utils;

/**
* HTTP request to fetch the list of messages in the authenticated user's inbox
Expand Down
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
package com.alex1304dev.jdash.api.request;
package com.github.alex1304.jdash.api.request;

import java.util.Base64;
import java.util.Map;

import com.alex1304dev.jdash.api.GDHttpRequest;
import com.alex1304dev.jdash.api.GDHttpResponseBuilder;
import com.alex1304dev.jdash.component.GDMessage;
import com.alex1304dev.jdash.util.Constants;
import com.alex1304dev.jdash.util.Utils;
import com.alex1304dev.jdash.util.robtopsweakcrypto.RobTopsWeakCrypto;
import com.github.alex1304.jdash.api.GDHttpRequest;
import com.github.alex1304.jdash.api.GDHttpResponseBuilder;
import com.github.alex1304.jdash.component.GDMessage;
import com.github.alex1304.jdash.util.Constants;
import com.github.alex1304.jdash.util.Utils;
import com.github.alex1304.jdash.util.robtopsweakcrypto.RobTopsWeakCrypto;

/**
* HTTP request to fetch private message contents
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
package com.alex1304dev.jdash.api.request;
package com.github.alex1304.jdash.api.request;

import java.util.Base64;

import com.alex1304dev.jdash.api.GDHttpRequest;
import com.alex1304dev.jdash.api.GDHttpResponseBuilder;
import com.alex1304dev.jdash.component.GDBoolean;
import com.alex1304dev.jdash.util.robtopsweakcrypto.RobTopsWeakCrypto;
import com.github.alex1304.jdash.api.GDHttpRequest;
import com.github.alex1304.jdash.api.GDHttpResponseBuilder;
import com.github.alex1304.jdash.component.GDBoolean;
import com.github.alex1304.jdash.util.robtopsweakcrypto.RobTopsWeakCrypto;

/**
* HTTP request to send a message in Geometry Dash
Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
package com.alex1304dev.jdash.api.request;
package com.github.alex1304.jdash.api.request;

import java.util.Map;

import com.alex1304dev.jdash.api.GDHttpRequest;
import com.alex1304dev.jdash.api.GDHttpResponseBuilder;
import com.alex1304dev.jdash.component.GDUser;
import com.alex1304dev.jdash.component.property.GDUserRole;
import com.alex1304dev.jdash.util.Constants;
import com.alex1304dev.jdash.util.Utils;
import com.github.alex1304.jdash.api.GDHttpRequest;
import com.github.alex1304.jdash.api.GDHttpResponseBuilder;
import com.github.alex1304.jdash.component.GDUser;
import com.github.alex1304.jdash.component.property.GDUserRole;
import com.github.alex1304.jdash.util.Constants;
import com.github.alex1304.jdash.util.Utils;

/**
* HTTP request to fetch a GD user.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
package com.alex1304dev.jdash.api.request;
package com.github.alex1304.jdash.api.request;

import java.util.Map;

import com.alex1304dev.jdash.api.GDHttpRequest;
import com.alex1304dev.jdash.api.GDHttpResponseBuilder;
import com.alex1304dev.jdash.component.GDComponentList;
import com.alex1304dev.jdash.component.GDUserPreview;
import com.alex1304dev.jdash.util.Constants;
import com.alex1304dev.jdash.util.Utils;
import com.github.alex1304.jdash.api.GDHttpRequest;
import com.github.alex1304.jdash.api.GDHttpResponseBuilder;
import com.github.alex1304.jdash.component.GDComponentList;
import com.github.alex1304.jdash.component.GDUserPreview;
import com.github.alex1304.jdash.util.Constants;
import com.github.alex1304.jdash.util.Utils;

/**
* HTTP request to search for users
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.alex1304dev.jdash.component;
package com.github.alex1304.jdash.component;

/**
* GD component that encapsulates a boolean
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.alex1304dev.jdash.component;
package com.github.alex1304.jdash.component;

/**
* A Geometry Dash component is any entity that can be found in the game.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.alex1304dev.jdash.component;
package com.github.alex1304.jdash.component;

import java.util.ArrayList;
import java.util.Collection;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package com.alex1304dev.jdash.component;
package com.github.alex1304.jdash.component;

import com.alex1304dev.jdash.component.property.GDLevelDemonDifficulty;
import com.alex1304dev.jdash.component.property.GDLevelDifficulty;
import com.alex1304dev.jdash.component.property.GDLevelLength;
import com.github.alex1304.jdash.component.property.GDLevelDemonDifficulty;
import com.github.alex1304.jdash.component.property.GDLevelDifficulty;
import com.github.alex1304.jdash.component.property.GDLevelLength;

/**
* Represents a level in the game.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package com.alex1304dev.jdash.component;
package com.github.alex1304.jdash.component;

import com.alex1304dev.jdash.component.property.GDLevelDemonDifficulty;
import com.alex1304dev.jdash.component.property.GDLevelDifficulty;
import com.alex1304dev.jdash.component.property.GDLevelLength;
import com.github.alex1304.jdash.component.property.GDLevelDemonDifficulty;
import com.github.alex1304.jdash.component.property.GDLevelDifficulty;
import com.github.alex1304.jdash.component.property.GDLevelLength;

/**
* Basic info on a GD level
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.alex1304dev.jdash.component;
package com.github.alex1304.jdash.component;

/**
* Represents a private message in Geometry Dash
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.alex1304dev.jdash.component;
package com.github.alex1304.jdash.component;

/**
* Represents a song used in GD levels
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.alex1304dev.jdash.component;
package com.github.alex1304.jdash.component;

import com.alex1304dev.jdash.component.property.GDUserRole;
import com.github.alex1304.jdash.component.property.GDUserRole;

/**
* Represents a user in Geometry Dash.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.alex1304dev.jdash.component;
package com.github.alex1304.jdash.component;

/**
* Represents a user preview when searching for them in Geometry Dash.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.alex1304dev.jdash.component.property;
package com.github.alex1304.jdash.component.property;

/**
* Represents the Demon difficulty of a GD level.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.alex1304dev.jdash.component.property;
package com.github.alex1304.jdash.component.property;

/**
* Represents the difficulty of a GD level
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.alex1304dev.jdash.component.property;
package com.github.alex1304.jdash.component.property;

/**
* Represents the length of a GD level
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.alex1304dev.jdash.component.property;
package com.github.alex1304.jdash.component.property;

/**
* User's role in Geometry Dash
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.alex1304dev.jdash.exceptions;
package com.github.alex1304.jdash.exceptions;

/**
* Thrown when a GD API call fails
Expand Down

0 comments on commit cc2e8b9

Please sign in to comment.