-
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.
* Refactor FeedRequest into EventSource, and FeedOptions. * Rename StreamTokenResponse -> EventSourceResponse (and codec). * Rename FeedSuccess -> FeedPage. * Add E2EFeedsTest.manualTest to show how customers can control the requests being made. * Rename some of the methods on FaunaClient.
- Loading branch information
David Griffin
committed
Oct 30, 2024
1 parent
1d96ef3
commit 144fd79
Showing
17 changed files
with
332 additions
and
211 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
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
package com.fauna.feed; | ||
|
||
import com.fauna.query.EventSourceResponse; | ||
|
||
public class EventSource { | ||
private final String token; | ||
|
||
public EventSource(String token) { | ||
this.token = token; | ||
} | ||
|
||
public String getToken() { | ||
return token; | ||
} | ||
|
||
public static EventSource fromToken(String token) { | ||
return new EventSource(token); | ||
} | ||
|
||
public static EventSource fromResponse(EventSourceResponse response) { | ||
return new EventSource(response.getToken()); | ||
} | ||
} |
Oops, something went wrong.