This repository has been archived by the owner on Jul 23, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #3 from SamOphis/dev-version
Update LavaClient to v1.2
- Loading branch information
Showing
11 changed files
with
98 additions
and
17 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
23 changes: 23 additions & 0 deletions
23
src/main/java/samophis/lavalink/client/entities/SocketInitializer.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,23 @@ | ||
package samophis.lavalink.client.entities; | ||
|
||
import com.neovisionaries.ws.client.WebSocket; | ||
import javax.annotation.Nonnull; | ||
|
||
/** | ||
* Represents an initializer that allows users to modify the raw WebSocket instance before LavaClient opens a connection to it. | ||
* <br><p>Any node created with this initializer will maintain its set properties even after being re-created. | ||
* Additionally, it is recommended to use the Java 8 Lambda features for code cleanliness. If you don't know how to use them LavaClient probably isn't the library for you.</p> | ||
* | ||
* @since 1.2 | ||
* @author SamOphis | ||
*/ | ||
|
||
@FunctionalInterface | ||
public interface SocketInitializer { | ||
/** | ||
* The actual method used to initialize a pre-created WebSocket before a connection is made with it. | ||
* @param socket A WebSocket instance. | ||
* @return A <b>not-null</b> WebSocket instance with the updated properties. | ||
*/ | ||
@Nonnull WebSocket initialize(WebSocket socket); | ||
} |
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