00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031 package org.objectweb.proactive.core.component;
00032
00033 import java.io.Serializable;
00034
00035 import org.apache.log4j.Logger;
00036 import org.objectweb.fractal.api.Interface;
00037 import org.objectweb.proactive.core.util.log.Loggers;
00038 import org.objectweb.proactive.core.util.log.ProActiveLogger;
00039
00040
00048 public class Binding implements Serializable {
00049 private static Logger logger = ProActiveLogger.getLogger(Loggers.COMPONENTS);
00050 private final ProActiveInterface clientInterface;
00051 private final ProActiveInterface serverInterface;
00052 private final String clientInterfaceName;
00053
00059 public Binding(final Interface clientInterface, String clientItfName,
00060 final Interface serverInterface) {
00061 this.clientInterface = (ProActiveInterface) clientInterface;
00062 this.clientInterfaceName = clientItfName;
00063 this.serverInterface = (ProActiveInterface) serverInterface;
00064 }
00065
00069 public Interface getClientInterface() {
00070 return clientInterface;
00071 }
00072
00076 public Interface getServerInterface() {
00077 if (logger.isDebugEnabled()) {
00078 logger.debug("returning " + serverInterface.getClass().getName());
00079 }
00080 return serverInterface;
00081 }
00082
00088 public String getClientInterfaceName() {
00089 return clientInterfaceName;
00090 }
00091 }