mirror of
https://github.com/proxiodev/RedisBungee.git
synced 2026-04-08 16:10:26 +00:00
make the api the plugin
This commit is contained in:
@@ -15,4 +15,33 @@
|
||||
*/
|
||||
package net.limework.valiobungee.api;
|
||||
|
||||
public interface ValioBungeeAPI {}
|
||||
import java.util.Optional;
|
||||
import java.util.Set;
|
||||
import java.util.UUID;
|
||||
import net.limework.valiobungee.api.entity.NetworkPlayer;
|
||||
import net.limework.valiobungee.api.entity.NetworkProxy;
|
||||
|
||||
public interface ValioBungeeAPI {
|
||||
|
||||
Optional<NetworkPlayer> getNetworkPlayer(UUID uuid);
|
||||
|
||||
Optional<NetworkProxy> getNetworkProxy(String id);
|
||||
|
||||
NetworkProxy getLocalProxy();
|
||||
|
||||
Set<NetworkProxy> getNetworkProxies();
|
||||
|
||||
Set<NetworkPlayer> getLocalProxyPlayers();
|
||||
|
||||
Set<NetworkPlayer> getNetworkPlayers();
|
||||
|
||||
/**
|
||||
* @return Version based on the build
|
||||
*/
|
||||
String getVersion();
|
||||
|
||||
/**
|
||||
* @return GIT COMMIT based on the build
|
||||
*/
|
||||
String getGitCommit();
|
||||
}
|
||||
|
||||
@@ -32,12 +32,12 @@ public interface NetworkProxy {
|
||||
/**
|
||||
* @return online players number in this proxy
|
||||
*/
|
||||
int onlinePlayersCount();
|
||||
int onlinePlayerCount();
|
||||
|
||||
/**
|
||||
* @return Returns set of players in this proxy
|
||||
*/
|
||||
Set<NetworkPlayer> networkPlayers();
|
||||
Set<NetworkPlayer> getProxyPlayers();
|
||||
|
||||
/**
|
||||
* @return returns true if this object is proxy on it
|
||||
|
||||
@@ -17,4 +17,10 @@ package net.limework.valiobungee.velocity.api;
|
||||
|
||||
import net.limework.valiobungee.api.ValioBungeeAPI;
|
||||
|
||||
/**
|
||||
* Valiobungee velocity specific API
|
||||
*
|
||||
* @author Ham1255
|
||||
* @since 1.0.0
|
||||
*/
|
||||
public interface VelocityValioBungeeAPI extends ValioBungeeAPI {}
|
||||
|
||||
@@ -13,26 +13,14 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package net.limework.valiobungee.api;
|
||||
package net.limework.valiobungee.velocity.api.entities;
|
||||
|
||||
import net.limework.valiobungee.api.entity.NetworkPlayer;
|
||||
|
||||
/**
|
||||
* this class provides the API object and access to the version and git commit
|
||||
* Velocity Network player.
|
||||
*
|
||||
* @author Ham1255
|
||||
* @since 1.0.0
|
||||
*/
|
||||
public interface ValioBungeeAPIProvider {
|
||||
/**
|
||||
* @return The api object {@link ValioBungeeAPI}
|
||||
*/
|
||||
ValioBungeeAPI getAPI();
|
||||
|
||||
/**
|
||||
* @return version of the build
|
||||
*/
|
||||
String getVersion();
|
||||
|
||||
/**
|
||||
* @return GIT COMMIT based on the build
|
||||
*/
|
||||
String getGitCommit();
|
||||
}
|
||||
public interface VelocityNetworkPlayer extends NetworkPlayer {}
|
||||
@@ -0,0 +1,26 @@
|
||||
/*
|
||||
* Copyright (c) 2026 ValioBungee contributors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* https://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package net.limework.valiobungee.velocity.api.entities;
|
||||
|
||||
import net.limework.valiobungee.api.entity.NetworkProxy;
|
||||
|
||||
/**
|
||||
* Proxy is an object for online proxy in a velocity network
|
||||
*
|
||||
* @author Ham1255
|
||||
* @since 1.0.0
|
||||
*/
|
||||
public interface VelocityNetworkProxy extends NetworkProxy {}
|
||||
Reference in New Issue
Block a user