-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
21c15fe
commit ae89116
Showing
8 changed files
with
806 additions
and
328 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
936 changes: 632 additions & 304 deletions
936
EasyInsta/src/main/java/com/xcoder/easyinsta/Instagram.java
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
14 changes: 14 additions & 0 deletions
14
EasyInsta/src/main/java/com/xcoder/easyinsta/exceptions/IGLoginException.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
package com.xcoder.easyinsta.exceptions; | ||
|
||
public class IGLoginException extends Exception { | ||
private final Reasons reason; | ||
|
||
public IGLoginException(String message, Reasons reason) { | ||
super(message); | ||
this.reason = reason; | ||
} | ||
|
||
public Reasons getReason() { | ||
return reason; | ||
} | ||
} |
14 changes: 14 additions & 0 deletions
14
EasyInsta/src/main/java/com/xcoder/easyinsta/exceptions/InstagramException.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
package com.xcoder.easyinsta.exceptions; | ||
|
||
public class InstagramException extends RuntimeException { | ||
private final Reasons reason; | ||
|
||
public InstagramException(String message, Reasons reason) { | ||
super(message); | ||
this.reason = reason; | ||
} | ||
|
||
public Reasons getReason() { | ||
return reason; | ||
} | ||
} |
18 changes: 18 additions & 0 deletions
18
EasyInsta/src/main/java/com/xcoder/easyinsta/exceptions/Reasons.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
package com.xcoder.easyinsta.exceptions; | ||
|
||
public enum Reasons { | ||
REQUIRE_2_FACTOR_AUTHENTICATION, | ||
LOGIN_ERROR_UNKNOWN, | ||
BIO_LENGTH_EXCEEDED, | ||
UNSUPPORTED_FILE_FORMAT, | ||
INVALID_CREDENTIALS, | ||
CHALLENGE_REQUIRED, | ||
CACHING_ERROR, | ||
PROXY_ERROR, | ||
NO_SUCH_ADMIN, | ||
INVALID_USERNAME, | ||
LOGIN_TOO_FREQUENTLY, | ||
API_RESPONSE_ERROR, | ||
NO_SUCH_MESSAGE | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters