You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
66 lines
1.0 KiB
66 lines
1.0 KiB
10 years ago
|
package mightypork.gamecore.core;
|
||
10 years ago
|
|
||
10 years ago
|
|
||
10 years ago
|
import mightypork.gamecore.eventbus.EventBus;
|
||
10 years ago
|
import mightypork.gamecore.input.InputSystem;
|
||
|
import mightypork.gamecore.render.DisplaySystem;
|
||
10 years ago
|
import mightypork.gamecore.resources.audio.SoundSystem;
|
||
10 years ago
|
|
||
|
|
||
|
/**
|
||
10 years ago
|
* App access adapter (defualt {@link AppAccess} implementation)
|
||
10 years ago
|
*
|
||
|
* @author MightyPork
|
||
|
*/
|
||
10 years ago
|
public class AppAccessAdapter implements AppAccess {
|
||
10 years ago
|
|
||
10 years ago
|
private final AppAccess app;
|
||
10 years ago
|
|
||
|
|
||
10 years ago
|
/**
|
||
|
* @param app app access
|
||
|
*/
|
||
10 years ago
|
public AppAccessAdapter(AppAccess app)
|
||
10 years ago
|
{
|
||
10 years ago
|
if (app == null) throw new NullPointerException("AppAccess instance cannot be null.");
|
||
10 years ago
|
|
||
10 years ago
|
this.app = app;
|
||
|
}
|
||
10 years ago
|
|
||
|
|
||
10 years ago
|
@Override
|
||
10 years ago
|
public final SoundSystem getSoundSystem()
|
||
10 years ago
|
{
|
||
10 years ago
|
return app.getSoundSystem();
|
||
10 years ago
|
}
|
||
10 years ago
|
|
||
|
|
||
10 years ago
|
@Override
|
||
10 years ago
|
public final InputSystem getInput()
|
||
10 years ago
|
{
|
||
10 years ago
|
return app.getInput();
|
||
10 years ago
|
}
|
||
10 years ago
|
|
||
|
|
||
10 years ago
|
@Override
|
||
10 years ago
|
public final DisplaySystem getDisplay()
|
||
10 years ago
|
{
|
||
10 years ago
|
return app.getDisplay();
|
||
10 years ago
|
}
|
||
10 years ago
|
|
||
|
|
||
10 years ago
|
@Override
|
||
10 years ago
|
public final EventBus getEventBus()
|
||
10 years ago
|
{
|
||
10 years ago
|
return app.getEventBus();
|
||
10 years ago
|
}
|
||
10 years ago
|
|
||
|
|
||
10 years ago
|
@Override
|
||
10 years ago
|
public final void shutdown()
|
||
10 years ago
|
{
|
||
|
app.shutdown();
|
||
|
}
|
||
10 years ago
|
|
||
10 years ago
|
}
|