Package org.jboss.as.ee.component.interceptors

Examples of org.jboss.as.ee.component.interceptors.InvocationType


    protected Object invokeEjbCreate(final Map<Object, Object> contextData, final Method ejbCreate, final EntityBeanComponentInstance instance, final Object[] params) throws Exception {

        //there will always be an invocation
        //as this is only used from home invocations
        final InterceptorContext context = CurrentInvocationContext.get();
        final InvocationType invocationType = context.getPrivateData(InvocationType.class);
        try {
            context.putPrivateData(InvocationType.class, InvocationType.ENTITY_EJB_CREATE);
            return ejbCreate.invoke(instance.getInstance(), params);
        } catch (InvocationTargetException e) {
            throw Interceptors.rethrow(e.getCause());
View Full Code Here


        }
    }

    public void setupContext(final InterceptorContext interceptorContext) {

        final InvocationType invocationType = interceptorContext.getPrivateData(InvocationType.class);
        try {
            interceptorContext.putPrivateData(InvocationType.class, InvocationType.SET_ENTITY_CONTEXT);
            final EntityContextImpl entityContext = new EntityContextImpl(this);
            setEjbContext(entityContext);
            getInstance().setEntityContext(entityContext);
View Full Code Here

    protected Object invokeEjbCreate(final Map<Object, Object> contextData, final Method ejbCreate, final EntityBeanComponentInstance instance, final Object[] params) throws Exception {

        //there will always be an invocation
        //as this is only used from home invocations
        final InterceptorContext context = CurrentInvocationContext.get();
        final InvocationType invocationType = context.getPrivateData(InvocationType.class);
        try {
            context.putPrivateData(InvocationType.class, InvocationType.ENTITY_EJB_CREATE);
            return ejbCreate.invoke(instance.getInstance(), params);
        } catch (InvocationTargetException e) {
            throw Interceptors.rethrow(e.getCause());
View Full Code Here

        return (CmpEntityBeanContext) super.getEjbContext();
    }

    @Override
    public void setupContext(final InterceptorContext interceptorContext) {
        final InvocationType invocationType = interceptorContext.getPrivateData(InvocationType.class);
        try {
            interceptorContext.putPrivateData(InvocationType.class, InvocationType.SET_ENTITY_CONTEXT);
            final CmpEntityBeanContext context = new CmpEntityBeanContext(this);
            setEjbContext(context);
            getInstance().setEntityContext(context);
View Full Code Here

        final Component component = context.getPrivateData(Component.class);
        if (!(component instanceof EJBComponent)) {
            return;
        }
        final InvocationType invocationType = context.getPrivateData(InvocationType.class);

        ((EJBComponent) component).getAllowedMethodsInformation().realCheckPermission(methodType, invocationType);

    }
View Full Code Here

        this.actions = actions;
    }

    @Override
    public Object processInvocation(final InterceptorContext context) throws Exception {
        final InvocationType invocationType = context.getPrivateData(InvocationType.class);
        if(invocationType == null) {
            return context.proceed();
        }
        switch (invocationType) {
            case TIMER:
View Full Code Here

        }
    }

    public void setupContext(final InterceptorContext interceptorContext) {

        final InvocationType invocationType = interceptorContext.getPrivateData(InvocationType.class);
        try {
            interceptorContext.putPrivateData(InvocationType.class, InvocationType.SET_ENTITY_CONTEXT);
            final EntityContextImpl entityContext = new EntityContextImpl(this);
            setEjbContext(entityContext);
            getInstance().setEntityContext(entityContext);
View Full Code Here

    protected Object invokeEjbCreate(final Map<Object, Object> contextData, final Method ejbCreate, final EntityBeanComponentInstance instance, final Object[] params) throws Exception {

        //there will always be an invocation
        //as this is only used from home invocations
        final InterceptorContext context = CurrentInvocationContext.get();
        final InvocationType invocationType = context.getPrivateData(InvocationType.class);
        try {
            context.putPrivateData(InvocationType.class, InvocationType.ENTITY_EJB_CREATE);
            return ejbCreate.invoke(instance.getInstance(), params);
        } catch (InvocationTargetException e) {
            throw Interceptors.rethrow(e.getCause());
View Full Code Here

        SessionBeanHomeInterceptorFactory.INIT_PARAMETERS.remove();
        return new AbstractEJBInterceptor() {
            @Override
            public Object processInvocation(final InterceptorContext context) throws Exception {
                if (method != null) {
                    final InvocationType invocationType = context.getPrivateData(InvocationType.class);
                    try {
                        context.putPrivateData(InvocationType.class, InvocationType.SFSB_INIT_METHOD);
                        method.invoke(context.getTarget(), params);
                    } catch (InvocationTargetException e) {
                        if (CreateException.class.isAssignableFrom(e.getCause().getClass())) {
View Full Code Here

            throw Interceptors.rethrow(e.getCause());
        }
    }

    protected Object invokeEjbCreate(final InterceptorContext context, final Method ejbCreate, final EntityBeanComponentInstance instance, final Object[] params) throws Exception {
        final InvocationType invocationType = context.getPrivateData(InvocationType.class);
        try {
            context.putPrivateData(InvocationType.class, InvocationType.ENTITY_EJB_CREATE);
            return ejbCreate.invoke(instance.getInstance(), params);
        } catch (InvocationTargetException e) {
            throw Interceptors.rethrow(e.getCause());
View Full Code Here

TOP

Related Classes of org.jboss.as.ee.component.interceptors.InvocationType

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.