01: /*
02: * JOSSO: Java Open Single Sign-On
03: *
04: * Copyright 2004-2008, Atricore, Inc.
05: *
06: * This is free software; you can redistribute it and/or modify it
07: * under the terms of the GNU Lesser General Public License as
08: * published by the Free Software Foundation; either version 2.1 of
09: * the License, or (at your option) any later version.
10: *
11: * This software is distributed in the hope that it will be useful,
12: * but WITHOUT ANY WARRANTY; without even the implied warranty of
13: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14: * Lesser General Public License for more details.
15: *
16: * You should have received a copy of the GNU Lesser General Public
17: * License along with this software; if not, write to the Free
18: * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
19: * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
20: */
21: package org.josso.gateway.event.client.ws.impl;
22:
23: import org.apache.commons.logging.Log;
24: import org.apache.commons.logging.LogFactory;
25: import org.josso.Lookup;
26:
27: import java.rmi.RemoteException;
28:
29: /**
30: * TODO : Add class description.
31: *
32: * @author <a href="mailto:sgonzalez@josso.org">Sebastian Gonzalez Oyuela</a>
33: * @version $Id: SSOEventManagerClientSoapBindingImpl.java 508 2008-02-18 13:32:29Z sgonzalez $
34: */
35: public class SSOEventManagerClientSoapBindingImpl implements
36: org.josso.gateway.event.client.ws.impl.SSOEventManagerClient {
37:
38: private static final Log logger = LogFactory
39: .getLog(SSOEventManagerClientSoapBindingImpl.class);
40:
41: public void fireSSOEvent(
42: org.josso.gateway.event.client.ws.impl.SSOEvent in0)
43: throws RemoteException,
44: org.josso.gateway.event.client.ws.impl.SSOEventException {
45: try {
46: org.josso.gateway.event.client.SSOEventManagerClient em = Lookup
47: .getInstance().lookupSSOEventManagerClient();
48: em.fireSSOEvent(addaptSSOEvent(in0));
49: } catch (Exception e) {
50: throw new org.josso.gateway.session.service.ws.impl.SSOSessionException();
51: }
52: }
53:
54: public void fireSessionEvent(String in0, String in1, String in2,
55: Object in3) throws RemoteException, SSOEventException {
56: try {
57: org.josso.gateway.event.client.SSOEventManagerClient em = Lookup
58: .getInstance().lookupSSOEventManagerClient();
59: em.fireSessionEvent(in0, in1, in2, addaptProperties(in3));
60: } catch (Exception e) {
61: throw new org.josso.gateway.session.service.ws.impl.SSOSessionException();
62: }
63: }
64:
65: protected org.josso.gateway.event.SSOEvent addaptSSOEvent(
66: org.josso.gateway.event.client.ws.impl.SSOEvent event) {
67: return new org.josso.gateway.event.security.BaseSSOSecurityEvent(
68: event.getType(), null);
69: }
70:
71: protected java.util.Properties addaptProperties(Object props) {
72: logger.debug(props.getClass().getName());
73: return new java.util.Properties();
74: }
75: }
|