--- /dev/null
+/*
+ * Copyright (C) 2015 Roland Haeder
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+package org.mxchange.addressbook.beans.addressbook;
+
+import javax.ejb.EJB;
+import javax.enterprise.context.SessionScoped;
+import javax.faces.view.facelets.FaceletException;
+import javax.inject.Named;
+import javax.naming.Context;
+import javax.naming.InitialContext;
+import javax.naming.NamingException;
+import org.mxchange.addressbook.beans.login.UserLoginWebController;
+import org.mxchange.addressbook.model.addressbooks.AddressbookSessionBeanRemote;
+
+/**
+ * A user bean (controller)
+ * <p>
+ * @author Roland Haeder<roland@mxchange.org>
+ */
+@Named ("addressbookController")
+@SessionScoped
+public class AddressbookWebBean implements AddressbookWebController {
+
+ /**
+ * Serial number
+ */
+ private static final long serialVersionUID = 185_781_756_712_969L;
+
+ /////////////////////// Properties /////////////////////
+
+ /**
+ * Remote addressbook bean
+ */
+ private final AddressbookSessionBeanRemote addressbookBean;
+
+ /**
+ * Login controller
+ */
+ @EJB
+ private UserLoginWebController loginController;
+
+ /**
+ * Default constructor
+ */
+ public AddressbookWebBean () {
+ // Try it
+ try {
+ // Get initial context
+ Context context = new InitialContext();
+
+ // Try to lookup
+ this.addressbookBean = (AddressbookSessionBeanRemote) context.lookup("ejb/stateless-addressbook"); //NOI18N
+ } catch (final NamingException e) {
+ // Throw again
+ throw new FaceletException(e);
+ }
+ }
+}
--- /dev/null
+/*
+ * Copyright (C) 2015 Roland Haeder
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ */
+package org.mxchange.addressbook.beans.addressbook;
+
+import java.io.Serializable;
+
+/**
+ * An interface for user beans
+ * <p>
+ * @author Roland Haeder<roland@mxchange.org>
+ */
+public interface AddressbookWebController extends Serializable {
+}