Search in sources :

Example 1 with EzyAddCommandImpl

use of com.tvd12.ezyfoxserver.command.impl.EzyAddCommandImpl in project ezyfox-server by youngmonkeys.

the class EzyAddCommandImplTest method test.

@Test
public void test() {
    EzyAbstractContext ctx = spy(EzyAbstractContext.class);
    ctx.init();
    EzyAddCommandImpl cmd = new EzyAddCommandImpl(ctx);
    cmd.add(Cmd.class, Cmd::new);
}
Also used : EzyAbstractContext(com.tvd12.ezyfoxserver.context.EzyAbstractContext) EzyAddCommandImpl(com.tvd12.ezyfoxserver.command.impl.EzyAddCommandImpl) BaseTest(com.tvd12.test.base.BaseTest) Test(org.testng.annotations.Test)

Example 2 with EzyAddCommandImpl

use of com.tvd12.ezyfoxserver.command.impl.EzyAddCommandImpl in project ezyfox-server by youngmonkeys.

the class EzyAbstractContext method init.

@Override
public final void init() {
    this.commandSuppliers = defaultCommandSuppliers();
    this.handleException = new EzyHandleExceptionImpl(component);
    this.properties.put(EzyHandleException.class, handleException);
    this.properties.put(EzyAddCommand.class, new EzyAddCommandImpl(this));
    this.properties.put(EzyAddExceptionHandler.class, new EzyAddExceptionHandlerImpl(component));
    this.doInit();
}
Also used : EzyAddExceptionHandlerImpl(com.tvd12.ezyfoxserver.command.impl.EzyAddExceptionHandlerImpl) EzyHandleExceptionImpl(com.tvd12.ezyfoxserver.command.impl.EzyHandleExceptionImpl) EzyAddCommandImpl(com.tvd12.ezyfoxserver.command.impl.EzyAddCommandImpl)

Aggregations

EzyAddCommandImpl (com.tvd12.ezyfoxserver.command.impl.EzyAddCommandImpl)2 EzyAddExceptionHandlerImpl (com.tvd12.ezyfoxserver.command.impl.EzyAddExceptionHandlerImpl)1 EzyHandleExceptionImpl (com.tvd12.ezyfoxserver.command.impl.EzyHandleExceptionImpl)1 EzyAbstractContext (com.tvd12.ezyfoxserver.context.EzyAbstractContext)1 BaseTest (com.tvd12.test.base.BaseTest)1 Test (org.testng.annotations.Test)1