All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.jboss.weld.ejb.spi.EjbDescriptor Maven / Gradle / Ivy

There is a newer version: 3.0.0.Alpha1
Show newest version
/*
 * JBoss, Home of Professional Open Source
 * Copyright 2010, Red Hat, Inc., and individual contributors
 * by the @authors tag. See the copyright.txt in the distribution for a
 * full listing of individual 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
 * http://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 org.jboss.weld.ejb.spi;

import java.lang.reflect.Method;
import java.util.Collection;

import javax.ejb.Stateful;

/**
 * EJB metadata from the EJB descriptor. The implementation may optionally implement {@link SubclassedComponentDescriptor}
 * if it uses an enhances subclass to implement EJB functionality.
 *
 * @author Pete Muir
 *
 * @param  the bean type
 */
public interface EjbDescriptor {

    /**
     * Gets the EJB type
     *
     * @return The EJB Bean class
     */
    Class getBeanClass();

    /**
     * Gets the local business interfaces of the EJB
     *
     * @return An iterator over the local business interfaces
     */
    Collection> getLocalBusinessInterfaces();

    /**
     * Gets the remote business interfaces of the EJB
     *
     * @return An iterator over the remote business interfaces
     */
    Collection> getRemoteBusinessInterfaces();

    /**
     * Get the EJB name
     *
     * @return
     */
    String getEjbName();

    /**
     * Get the remove methods of the EJB
     *
     * @return An iterator over the remove methods
     */
    Collection getRemoveMethods();

    /**
     * Indicates if the bean is a stateless session bean
     *
     * @return True if stateless, false otherwise
     */
    boolean isStateless();

    /**
     * Indicates if the bean is a EJB 3.1 Singleton session bean
     *
     * @return True if the bean is a singleton, false otherwise
     */
    boolean isSingleton();

    /**
     * Indicates if the EJB is a stateful session bean
     *
     * @return True if the bean is stateful, false otherwise
     */
    boolean isStateful();

    /**
     * Indicates if the EJB is an MDB
     *
     * @return True if the bean is an MDB, false otherwise
     */
    boolean isMessageDriven();

    /**
     * 

* Indicates if the EJB is passivation capable. *

*
    *
  • Stateless session beans, singleton session beans and MDBs are not passivation capable.
  • *
  • A stateful session bean is passivation capable unless the passivationCapable element of the * {@link Stateful} annotation is set to false or the passivation-capable element of the session * deployment descriptor element is set to false
  • *
*

* * @return true if the EJB is passivation capable */ boolean isPassivationCapable(); }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy