mirror of
https://github.com/SimplexDevelopment/FreedomNetworkSuite.git
synced 2025-07-05 06:56:40 +00:00
updates 🎱
This commit is contained in:
@ -16,25 +16,23 @@ public class CommonsBase extends JavaPlugin
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onEnable()
|
||||
public void onDisable()
|
||||
{
|
||||
getRegistrations().getServiceRegistry().register(this, eventBus);
|
||||
getExecutor().getSync()
|
||||
.execute(() -> getRegistrations()
|
||||
.getServiceRegistry()
|
||||
.startAll());
|
||||
getRegistrations().getServiceRegistry()
|
||||
.stopAll();
|
||||
getRegistrations().getServiceRegistry()
|
||||
.unregister(EventBus.class, eventBus);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onDisable()
|
||||
public void onEnable()
|
||||
{
|
||||
getRegistrations().getServiceRegistry().stopAll();
|
||||
getRegistrations().getServiceRegistry().unregister(EventBus.class, eventBus);
|
||||
}
|
||||
|
||||
public Registration getRegistrations()
|
||||
{
|
||||
return registration;
|
||||
getRegistrations().getServiceRegistry()
|
||||
.register(this, eventBus);
|
||||
getExecutor().getSync()
|
||||
.execute(() -> getRegistrations()
|
||||
.getServiceRegistry()
|
||||
.startAll());
|
||||
}
|
||||
|
||||
public FreedomExecutor getExecutor()
|
||||
@ -42,6 +40,11 @@ public class CommonsBase extends JavaPlugin
|
||||
return executor;
|
||||
}
|
||||
|
||||
public Registration getRegistrations()
|
||||
{
|
||||
return registration;
|
||||
}
|
||||
|
||||
public EventBus getEventBus()
|
||||
{
|
||||
return eventBus;
|
||||
|
@ -1,12 +1,11 @@
|
||||
package me.totalfreedom.base;
|
||||
|
||||
import me.totalfreedom.data.GroupRegistry;
|
||||
import me.totalfreedom.data.BanRegistry;
|
||||
import me.totalfreedom.data.ConfigRegistry;
|
||||
import me.totalfreedom.data.EventRegistry;
|
||||
import me.totalfreedom.data.GroupRegistry;
|
||||
import me.totalfreedom.data.ModuleRegistry;
|
||||
import me.totalfreedom.data.ServiceRegistry;
|
||||
import me.totalfreedom.data.UserRegistry;
|
||||
import me.totalfreedom.data.EventRegistry;
|
||||
|
||||
public class Registration
|
||||
{
|
||||
@ -15,7 +14,6 @@ public class Registration
|
||||
private final ServiceRegistry serviceRegistry;
|
||||
private final ModuleRegistry moduleRegistry;
|
||||
private final GroupRegistry groupRegistry;
|
||||
private final BanRegistry banRegistry;
|
||||
private final ConfigRegistry configRegistry;
|
||||
|
||||
public Registration()
|
||||
@ -25,8 +23,7 @@ public class Registration
|
||||
this.serviceRegistry = new ServiceRegistry();
|
||||
this.moduleRegistry = new ModuleRegistry();
|
||||
this.groupRegistry = new GroupRegistry();
|
||||
this.banRegistry = new BanRegistry();
|
||||
this.configRegistry = new ConfigRegistry();
|
||||
this.configRegistry = new ConfigRegistry();
|
||||
}
|
||||
|
||||
public ModuleRegistry getModuleRegistry()
|
||||
@ -54,11 +51,6 @@ public class Registration
|
||||
return groupRegistry;
|
||||
}
|
||||
|
||||
public BanRegistry getBanRegistry()
|
||||
{
|
||||
return banRegistry;
|
||||
}
|
||||
|
||||
public ConfigRegistry getConfigRegistry()
|
||||
{
|
||||
return configRegistry;
|
||||
|
Reference in New Issue
Block a user