LocalHome annotation (Open EJB) : Open EJB « EJB3 « Java






LocalHome annotation (Open EJB)

/**
 * Licensed to the Apache Software Foundation (ASF) under one or more
 * contributor license agreements.  See the NOTICE file distributed with
 * this work for additional information regarding copyright ownership.
 * The ASF licenses this file to You 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.superbiz.hello;

import javax.ejb.EJBLocalHome;
import javax.ejb.CreateException;

/**
 * @version $Revision: 607077 $ $Date: 2007-12-27 06:55:23 -0800 (Thu, 27 Dec 2007) $
 */
public interface HelloEjbLocalHome extends EJBLocalHome {
    HelloEjbLocal create() throws CreateException;
}

///////////////////////////
/**
 * Licensed to the Apache Software Foundation (ASF) under one or more
 * contributor license agreements.  See the NOTICE file distributed with
 * this work for additional information regarding copyright ownership.
 * The ASF licenses this file to You 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.superbiz.hello;

import javax.ejb.EJBLocalObject;

/**
 * @version $Revision: 607077 $ $Date: 2007-12-27 06:55:23 -0800 (Thu, 27 Dec 2007) $
 */
public interface HelloEjbLocal extends EJBLocalObject {

    String sayHello();

}

  
///////////////////////////
/**
 * Licensed to the Apache Software Foundation (ASF) under one or more
 * contributor license agreements.  See the NOTICE file distributed with
 * this work for additional information regarding copyright ownership.
 * The ASF licenses this file to You 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.superbiz.hello;

import javax.ejb.LocalHome;
import javax.ejb.Stateless;

/**
 * @version $Revision: 607077 $ $Date: 2007-12-27 06:55:23 -0800 (Thu, 27 Dec 2007) $
 */
@Stateless
@LocalHome(HelloEjbLocalHome.class)
public class HelloBean {

    public String sayHello() {
        return "Hello, World!";
    }

}

  
      
  








OpenEjBhelloworld-weblogic.zip( 14 k)

Related examples in the same category

1.component interfaces (Open EJB)
2.custom injection (Open EJB)
3.injection of datasource
4.injection of entitymanager and entity class
5.jpa hibernate (Open EJB)
6.Stateful session bean simple
7.stateless EJB for calculation
8.web service and Stateless session bean (Open EJB)
9.Web application based on EJB
10.Transaction in EJB
11.EJB security testing
12.Remote stab
13.injection of ejbs
14.injection of env entry
15.Use interceptors to inspect EJB