-
Notifications
You must be signed in to change notification settings - Fork 0
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
e50787a
commit 6afe466
Showing
3 changed files
with
21 additions
and
5 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -18,16 +18,16 @@ Jitpack recommends it be placed at the end of the repositories scope. | |
`maven { url 'https://jitpack.io' }` | ||
|
||
Then add the following to your dependencies: | ||
`implementation 'com.github.nathancheshire:gravatarjavaclient:2.0.3'`. | ||
`implementation 'com.github.nathancheshire:gravatarjavaclient:2.0.4'`. | ||
|
||
# Jitpack | ||
|
||
These links are mostly for me but if you would like to view the official Jitpack build log or artifacts list, these | ||
are the following links: | ||
|
||
Artifacts: https://jitpack.io/com/github/nathancheshire/gravatarjavaclient/2.0.3/ | ||
Artifacts: https://jitpack.io/com/github/nathancheshire/gravatarjavaclient/2.0.4/ | ||
|
||
Build log: https://jitpack.io/com/github/nathancheshire/gravatarjavaclient/2.0.3/build.log | ||
Build log: https://jitpack.io/com/github/nathancheshire/gravatarjavaclient/2.0.4/build.log | ||
|
||
## API Support | ||
|
||
|
@@ -75,6 +75,22 @@ GravatarProfile profileWithAuthenticatedFields = GravatarProfileRequest.fromEmai | |
.getProfile(); | ||
``` | ||
|
||
For generating QR codes: | ||
|
||
```java | ||
// Create the request | ||
GravatarQrCodeRequest request = GravatarQrCodeRequest.fromEmail("[email protected]") | ||
.setSize(800) | ||
.setImageType(GravatarQrImageType.USER) | ||
.setVersion(GravatarQrImageVersion.THREE); | ||
|
||
// Get a BufferedImage | ||
BufferedImage image = request.getBufferedImage(); | ||
|
||
// Save to a local file (API returns a PNG image) | ||
boolean wasSaved = request.saveTo(new File("path/to/your/file.png")); | ||
``` | ||
|
||
Because `GravatarProfileRequest` accepts a `GravatarProfileTokenProvider` instead of a literal string, you as the | ||
developer have the ability to prevent token strings from appearing in the string pool if you deem it to be worth | ||
the effort. Instead of simply returning a string from the provider, the provider returns a byte array which allows | ||
|
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