notify-dpml AT lists.ibiblio.org
Subject: DPML Notify
List archive
svn commit: r2105 - development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels
- From: niclas AT hedhman.org
- To: notify-dpml AT lists.ibiblio.org
- Subject: svn commit: r2105 - development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels
- Date: Mon, 21 Mar 2005 12:33:25 -0500
Author: niclas AT hedhman.org
Date: Mon Mar 21 12:33:25 2005
New Revision: 2105
Added:
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/ConfigHelper.java
(contents, props changed)
Modified:
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/AsciiChannel.java
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/Base24Channel.java
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/Base24TcpChannel.java
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/CsChannel.java
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/LogChannel.java
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/NacChannel.java
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/NccChannel.java
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/PadChannel.java
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/PostChannel.java
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/RawChannel.java
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/VapChannel.java
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/X25Channel.java
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/XmlChannel.java
Log:
Support for more configuration in the channels.
Modified:
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/AsciiChannel.java
==============================================================================
---
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/AsciiChannel.java
(original)
+++
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/AsciiChannel.java
Mon Mar 21 12:33:25 2005
@@ -18,6 +18,8 @@
package net.dpml.iso8583.parts.channels;
+import java.io.IOException;
+
import net.dpml.logging.Logger;
import net.dpml.parameters.ParameterException;
@@ -26,6 +28,7 @@
import net.dpml.service.ServiceException;
import net.dpml.service.ServiceManager;
+import org.jpos.iso.ISOException;
import org.jpos.iso.ISOPackager;
/** Metro Wrapper for the Ascii Channel in JPos.
@@ -39,13 +42,22 @@
/**
* @metro.logger name="Ascii"
* @metro.dependency type="org.jpos.iso.ISOPackager" key="packager"
+ *
+ * @metro.dependency type="org.jpos.iso.ISOServerSocketFactory"
+ * key="server-socket-factory"
+ * optional="true"
+ *
+ * @metro.dependency type="org.jpos.iso.ISOClientSocketFactory"
+ * key="client-socket-factory"
+ * optional="true"
*/
public AsciiChannel( Logger logger, ServiceManager man, Parameters
params )
- throws ServiceException, ParameterException
+ throws ServiceException, ParameterException, IOException,
ISOException
{
super( params.getParameter( "host" ),
params.getParameterAsInteger( "port" ),
(ISOPackager) man.lookup( "packager" )
);
+ ConfigHelper.initialize( this, man, params );
}
}
\ No newline at end of file
Modified:
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/Base24Channel.java
==============================================================================
---
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/Base24Channel.java
(original)
+++
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/Base24Channel.java
Mon Mar 21 12:33:25 2005
@@ -18,6 +18,8 @@
package net.dpml.iso8583.parts.channels;
+import java.io.IOException;
+
import net.dpml.logging.Logger;
import net.dpml.parameters.ParameterException;
@@ -26,6 +28,7 @@
import net.dpml.service.ServiceException;
import net.dpml.service.ServiceManager;
+import org.jpos.iso.ISOException;
import org.jpos.iso.ISOPackager;
/** Metro Wrapper for the BASE24 Channel in JPos.
@@ -39,13 +42,22 @@
/**
* @metro.logger name="Base24"
* @metro.dependency type="org.jpos.iso.ISOPackager" key="packager"
+ *
+ * @metro.dependency type="org.jpos.iso.ISOServerSocketFactory"
+ * key="server-socket-factory"
+ * optional="true"
+ *
+ * @metro.dependency type="org.jpos.iso.ISOClientSocketFactory"
+ * key="client-socket-factory"
+ * optional="true"
*/
public Base24Channel( Logger logger, ServiceManager man, Parameters
params )
- throws ServiceException, ParameterException
+ throws ServiceException, ParameterException, IOException,
ISOException
{
super( params.getParameter( "host" ),
params.getParameterAsInteger( "port" ),
(ISOPackager) man.lookup( "packager" )
);
+ ConfigHelper.initialize( this, man, params );
}
}
\ No newline at end of file
Modified:
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/Base24TcpChannel.java
==============================================================================
---
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/Base24TcpChannel.java
(original)
+++
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/Base24TcpChannel.java
Mon Mar 21 12:33:25 2005
@@ -18,6 +18,8 @@
package net.dpml.iso8583.parts.channels;
+import java.io.IOException;
+
import net.dpml.logging.Logger;
import net.dpml.parameters.ParameterException;
@@ -26,6 +28,7 @@
import net.dpml.service.ServiceException;
import net.dpml.service.ServiceManager;
+import org.jpos.iso.ISOException;
import org.jpos.iso.ISOPackager;
/** Metro Wrapper for the BASE24 TCP Channel in JPos.
@@ -39,13 +42,22 @@
/**
* @metro.logger name="Base24Tcp"
* @metro.dependency type="org.jpos.iso.ISOPackager" key="packager"
+ *
+ * @metro.dependency type="org.jpos.iso.ISOServerSocketFactory"
+ * key="server-socket-factory"
+ * optional="true"
+ *
+ * @metro.dependency type="org.jpos.iso.ISOClientSocketFactory"
+ * key="client-socket-factory"
+ * optional="true"
*/
public Base24TcpChannel( Logger logger, ServiceManager man, Parameters
params )
- throws ServiceException, ParameterException
+ throws ServiceException, ParameterException, IOException,
ISOException
{
super( params.getParameter( "host" ),
params.getParameterAsInteger( "port" ),
(ISOPackager) man.lookup( "packager" )
);
+ ConfigHelper.initialize( this, man, params );
}
}
\ No newline at end of file
Added:
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/ConfigHelper.java
==============================================================================
--- (empty file)
+++
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/ConfigHelper.java
Mon Mar 21 12:33:25 2005
@@ -0,0 +1,63 @@
+/*
+* Copyright 2004-2005 Niclas Hedhman.
+ *
+ * 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 net.dpml.iso8583.parts.channels;
+
+import java.io.IOException;
+
+import java.net.ServerSocket;
+
+import net.dpml.parameters.ParameterException;
+import net.dpml.parameters.Parameters;
+
+import net.dpml.service.ServiceException;
+import net.dpml.service.ServiceManager;
+
+import org.jpos.iso.BaseChannel;
+import org.jpos.iso.ISOException;
+import org.jpos.iso.ISOServerSocketFactory;
+import org.jpos.iso.ISOClientSocketFactory;
+
+class ConfigHelper
+{
+ static void initialize( BaseChannel ch, ServiceManager man, Parameters
params )
+ throws ServiceException, ParameterException, IOException,
ISOException
+ {
+ if( man.hasService( "server-socket-factory" ) )
+ {
+ ISOServerSocketFactory ssf = (ISOServerSocketFactory)
man.lookup( "server-socket-factory" );
+ ServerSocket socket = ssf.createServerSocket( ch.getPort() );
+ ch.setServerSocket( socket );
+ }
+ if( man.hasService( "client-socket-factory" ) )
+ {
+ ISOClientSocketFactory csf = (ISOClientSocketFactory)
man.lookup( "client-socket-factory" );
+ ch.setSocketFactory( csf );
+ }
+ int timeout = params.getParameterAsInteger( "timeout",
Integer.MIN_VALUE );
+ if( timeout != Integer.MIN_VALUE )
+ {
+ ch.setTimeout( timeout );
+ }
+ String header = params.getParameter( "header", null );
+ if( header != null )
+ {
+ ch.setHeader( header );
+ }
+ }
+}
Modified:
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/CsChannel.java
==============================================================================
---
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/CsChannel.java
(original)
+++
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/CsChannel.java
Mon Mar 21 12:33:25 2005
@@ -18,6 +18,8 @@
package net.dpml.iso8583.parts.channels;
+import java.io.IOException;
+
import net.dpml.logging.Logger;
import net.dpml.parameters.ParameterException;
@@ -26,6 +28,7 @@
import net.dpml.service.ServiceException;
import net.dpml.service.ServiceManager;
+import org.jpos.iso.ISOException;
import org.jpos.iso.ISOPackager;
/** Metro Wrapper for the CS Channel in JPos.
@@ -39,13 +42,22 @@
/**
* @metro.logger name="CS"
* @metro.dependency type="org.jpos.iso.ISOPackager" key="packager"
+ *
+ * @metro.dependency type="org.jpos.iso.ISOServerSocketFactory"
+ * key="server-socket-factory"
+ * optional="true"
+ *
+ * @metro.dependency type="org.jpos.iso.ISOClientSocketFactory"
+ * key="client-socket-factory"
+ * optional="true"
*/
public CsChannel( Logger logger, ServiceManager man, Parameters params )
- throws ServiceException, ParameterException
+ throws ServiceException, ParameterException, IOException,
ISOException
{
super( params.getParameter( "host" ),
params.getParameterAsInteger( "port" ),
(ISOPackager) man.lookup( "packager" )
);
+ ConfigHelper.initialize( this, man, params );
}
}
\ No newline at end of file
Modified:
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/LogChannel.java
==============================================================================
---
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/LogChannel.java
(original)
+++
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/LogChannel.java
Mon Mar 21 12:33:25 2005
@@ -18,6 +18,8 @@
package net.dpml.iso8583.parts.channels;
+import java.io.IOException;
+
import net.dpml.logging.Logger;
import net.dpml.parameters.ParameterException;
@@ -26,6 +28,7 @@
import net.dpml.service.ServiceException;
import net.dpml.service.ServiceManager;
+import org.jpos.iso.ISOException;
import org.jpos.iso.ISOPackager;
/** Metro Wrapper for the Log Channel in JPos.
@@ -39,13 +42,22 @@
/**
* @metro.logger name="Log"
* @metro.dependency type="org.jpos.iso.ISOPackager" key="packager"
+ *
+ * @metro.dependency type="org.jpos.iso.ISOServerSocketFactory"
+ * key="server-socket-factory"
+ * optional="true"
+ *
+ * @metro.dependency type="org.jpos.iso.ISOClientSocketFactory"
+ * key="client-socket-factory"
+ * optional="true"
*/
public LogChannel( Logger logger, ServiceManager man, Parameters params )
- throws ServiceException, ParameterException
+ throws ServiceException, ParameterException, IOException,
ISOException
{
super( params.getParameter( "host" ),
params.getParameterAsInteger( "port" ),
(ISOPackager) man.lookup( "packager" )
);
+ ConfigHelper.initialize( this, man, params );
}
}
\ No newline at end of file
Modified:
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/NacChannel.java
==============================================================================
---
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/NacChannel.java
(original)
+++
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/NacChannel.java
Mon Mar 21 12:33:25 2005
@@ -18,6 +18,8 @@
package net.dpml.iso8583.parts.channels;
+import java.io.IOException;
+
import java.util.StringTokenizer;
import net.dpml.logging.Logger;
@@ -28,6 +30,7 @@
import net.dpml.service.ServiceException;
import net.dpml.service.ServiceManager;
+import org.jpos.iso.ISOException;
import org.jpos.iso.ISOPackager;
/** Metro Wrapper for the NAC Channel in JPos.
@@ -41,15 +44,24 @@
/**
* @metro.logger name="NAC"
* @metro.dependency type="org.jpos.iso.ISOPackager" key="packager"
+ *
+ * @metro.dependency type="org.jpos.iso.ISOServerSocketFactory"
+ * key="server-socket-factory"
+ * optional="true"
+ *
+ * @metro.dependency type="org.jpos.iso.ISOClientSocketFactory"
+ * key="client-socket-factory"
+ * optional="true"
*/
public NacChannel( Logger logger, ServiceManager man, Parameters params )
- throws ServiceException, ParameterException
+ throws ServiceException, ParameterException, IOException,
ISOException
{
super( params.getParameter( "host" ),
params.getParameterAsInteger( "port" ),
(ISOPackager) man.lookup( "packager" ),
convertByteArray( params )
);
+ ConfigHelper.initialize( this, man, params );
}
private static byte[] convertByteArray( Parameters params )
Modified:
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/NccChannel.java
==============================================================================
---
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/NccChannel.java
(original)
+++
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/NccChannel.java
Mon Mar 21 12:33:25 2005
@@ -18,6 +18,8 @@
package net.dpml.iso8583.parts.channels;
+import java.io.IOException;
+
import java.util.StringTokenizer;
import net.dpml.logging.Logger;
@@ -28,6 +30,7 @@
import net.dpml.service.ServiceException;
import net.dpml.service.ServiceManager;
+import org.jpos.iso.ISOException;
import org.jpos.iso.ISOPackager;
/** Metro Wrapper for the NCC Channel in JPos.
@@ -41,15 +44,24 @@
/**
* @metro.logger name="NCC"
* @metro.dependency type="org.jpos.iso.ISOPackager" key="packager"
+ *
+ * @metro.dependency type="org.jpos.iso.ISOServerSocketFactory"
+ * key="server-socket-factory"
+ * optional="true"
+ *
+ * @metro.dependency type="org.jpos.iso.ISOClientSocketFactory"
+ * key="client-socket-factory"
+ * optional="true"
*/
public NccChannel( Logger logger, ServiceManager man, Parameters params )
- throws ServiceException, ParameterException
+ throws ServiceException, ParameterException, IOException,
ISOException
{
super( params.getParameter( "host" ),
params.getParameterAsInteger( "port" ),
(ISOPackager) man.lookup( "packager" ),
convertByteArray( params )
);
+ ConfigHelper.initialize( this, man, params );
}
private static byte[] convertByteArray( Parameters params )
Modified:
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/PadChannel.java
==============================================================================
---
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/PadChannel.java
(original)
+++
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/PadChannel.java
Mon Mar 21 12:33:25 2005
@@ -18,6 +18,8 @@
package net.dpml.iso8583.parts.channels;
+import java.io.IOException;
+
import net.dpml.logging.Logger;
import net.dpml.parameters.ParameterException;
@@ -26,6 +28,7 @@
import net.dpml.service.ServiceException;
import net.dpml.service.ServiceManager;
+import org.jpos.iso.ISOException;
import org.jpos.iso.ISOPackager;
/** Metro Wrapper for the x.25 PAD Channel in JPos.
@@ -39,13 +42,22 @@
/**
* @metro.logger name="PAD"
* @metro.dependency type="org.jpos.iso.ISOPackager" key="packager"
+ *
+ * @metro.dependency type="org.jpos.iso.ISOServerSocketFactory"
+ * key="server-socket-factory"
+ * optional="true"
+ *
+ * @metro.dependency type="org.jpos.iso.ISOClientSocketFactory"
+ * key="client-socket-factory"
+ * optional="true"
*/
public PadChannel( Logger logger, ServiceManager man, Parameters params )
- throws ServiceException, ParameterException
+ throws ServiceException, ParameterException, IOException,
ISOException
{
super( params.getParameter( "host" ),
params.getParameterAsInteger( "port" ),
(ISOPackager) man.lookup( "packager" )
);
+ ConfigHelper.initialize( this, man, params );
}
}
\ No newline at end of file
Modified:
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/PostChannel.java
==============================================================================
---
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/PostChannel.java
(original)
+++
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/PostChannel.java
Mon Mar 21 12:33:25 2005
@@ -18,6 +18,8 @@
package net.dpml.iso8583.parts.channels;
+import java.io.IOException;
+
import net.dpml.logging.Logger;
import net.dpml.parameters.ParameterException;
@@ -26,6 +28,7 @@
import net.dpml.service.ServiceException;
import net.dpml.service.ServiceManager;
+import org.jpos.iso.ISOException;
import org.jpos.iso.ISOPackager;
/** Metro Wrapper for the Post Channel in JPos.
@@ -39,13 +42,22 @@
/**
* @metro.logger name="Post"
* @metro.dependency type="org.jpos.iso.ISOPackager" key="packager"
+ *
+ * @metro.dependency type="org.jpos.iso.ISOServerSocketFactory"
+ * key="server-socket-factory"
+ * optional="true"
+ *
+ * @metro.dependency type="org.jpos.iso.ISOClientSocketFactory"
+ * key="client-socket-factory"
+ * optional="true"
*/
public PostChannel( Logger logger, ServiceManager man, Parameters params
)
- throws ServiceException, ParameterException
+ throws ServiceException, ParameterException, IOException,
ISOException
{
super( params.getParameter( "host" ),
params.getParameterAsInteger( "port" ),
(ISOPackager) man.lookup( "packager" )
);
+ ConfigHelper.initialize( this, man, params );
}
}
\ No newline at end of file
Modified:
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/RawChannel.java
==============================================================================
---
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/RawChannel.java
(original)
+++
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/RawChannel.java
Mon Mar 21 12:33:25 2005
@@ -18,6 +18,8 @@
package net.dpml.iso8583.parts.channels;
+import java.io.IOException;
+
import java.util.StringTokenizer;
import net.dpml.logging.Logger;
@@ -28,6 +30,7 @@
import net.dpml.service.ServiceException;
import net.dpml.service.ServiceManager;
+import org.jpos.iso.ISOException;
import org.jpos.iso.ISOPackager;
/** Metro Wrapper for the Raw Channel in JPos.
@@ -41,15 +44,24 @@
/**
* @metro.logger name="NCC"
* @metro.dependency type="org.jpos.iso.ISOPackager" key="packager"
+ *
+ * @metro.dependency type="org.jpos.iso.ISOServerSocketFactory"
+ * key="server-socket-factory"
+ * optional="true"
+ *
+ * @metro.dependency type="org.jpos.iso.ISOClientSocketFactory"
+ * key="client-socket-factory"
+ * optional="true"
*/
public RawChannel( Logger logger, ServiceManager man, Parameters params )
- throws ServiceException, ParameterException
+ throws ServiceException, ParameterException, IOException,
ISOException
{
super( params.getParameter( "host" ),
params.getParameterAsInteger( "port" ),
(ISOPackager) man.lookup( "packager" ),
convertByteArray( params )
);
+ ConfigHelper.initialize( this, man, params );
}
private static byte[] convertByteArray( Parameters params )
Modified:
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/VapChannel.java
==============================================================================
---
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/VapChannel.java
(original)
+++
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/VapChannel.java
Mon Mar 21 12:33:25 2005
@@ -18,6 +18,8 @@
package net.dpml.iso8583.parts.channels;
+import java.io.IOException;
+
import net.dpml.logging.Logger;
import net.dpml.parameters.ParameterException;
@@ -26,6 +28,7 @@
import net.dpml.service.ServiceException;
import net.dpml.service.ServiceManager;
+import org.jpos.iso.ISOException;
import org.jpos.iso.ISOPackager;
/** Metro Wrapper for the VAP Channel in JPos.
@@ -39,13 +42,22 @@
/**
* @metro.logger name="VAP"
* @metro.dependency type="org.jpos.iso.ISOPackager" key="packager"
+ *
+ * @metro.dependency type="org.jpos.iso.ISOServerSocketFactory"
+ * key="server-socket-factory"
+ * optional="true"
+ *
+ * @metro.dependency type="org.jpos.iso.ISOClientSocketFactory"
+ * key="client-socket-factory"
+ * optional="true"
*/
public VapChannel( Logger logger, ServiceManager man, Parameters params )
- throws ServiceException, ParameterException
+ throws ServiceException, ParameterException, IOException,
ISOException
{
super( params.getParameter( "host" ),
params.getParameterAsInteger( "port" ),
(ISOPackager) man.lookup( "packager" )
);
+ ConfigHelper.initialize( this, man, params );
}
}
\ No newline at end of file
Modified:
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/X25Channel.java
==============================================================================
---
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/X25Channel.java
(original)
+++
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/X25Channel.java
Mon Mar 21 12:33:25 2005
@@ -18,6 +18,8 @@
package net.dpml.iso8583.parts.channels;
+import java.io.IOException;
+
import net.dpml.logging.Logger;
import net.dpml.parameters.ParameterException;
@@ -26,6 +28,7 @@
import net.dpml.service.ServiceException;
import net.dpml.service.ServiceManager;
+import org.jpos.iso.ISOException;
import org.jpos.iso.ISOPackager;
/** Metro Wrapper for the x.25 Channel in JPos.
@@ -39,13 +42,22 @@
/**
* @metro.logger name="x.25"
* @metro.dependency type="org.jpos.iso.ISOPackager" key="packager"
+ *
+ * @metro.dependency type="org.jpos.iso.ISOServerSocketFactory"
+ * key="server-socket-factory"
+ * optional="true"
+ *
+ * @metro.dependency type="org.jpos.iso.ISOClientSocketFactory"
+ * key="client-socket-factory"
+ * optional="true"
*/
public X25Channel( Logger logger, ServiceManager man, Parameters params )
- throws ServiceException, ParameterException
+ throws ServiceException, ParameterException, IOException,
ISOException
{
super( params.getParameter( "host" ),
params.getParameterAsInteger( "port" ),
(ISOPackager) man.lookup( "packager" )
);
+ ConfigHelper.initialize( this, man, params );
}
}
\ No newline at end of file
Modified:
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/XmlChannel.java
==============================================================================
---
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/XmlChannel.java
(original)
+++
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/XmlChannel.java
Mon Mar 21 12:33:25 2005
@@ -18,6 +18,8 @@
package net.dpml.iso8583.parts.channels;
+import java.io.IOException;
+
import net.dpml.logging.Logger;
import net.dpml.parameters.ParameterException;
@@ -26,6 +28,7 @@
import net.dpml.service.ServiceException;
import net.dpml.service.ServiceManager;
+import org.jpos.iso.ISOException;
import org.jpos.iso.ISOPackager;
/** Metro Wrapper for the x.25 Channel in JPos.
@@ -39,13 +42,22 @@
/**
* @metro.logger name="XML"
* @metro.dependency type="org.jpos.iso.ISOPackager" key="packager"
+ *
+ * @metro.dependency type="org.jpos.iso.ISOServerSocketFactory"
+ * key="server-socket-factory"
+ * optional="true"
+ *
+ * @metro.dependency type="org.jpos.iso.ISOClientSocketFactory"
+ * key="client-socket-factory"
+ * optional="true"
*/
public XmlChannel( Logger logger, ServiceManager man, Parameters params )
- throws ServiceException, ParameterException
+ throws ServiceException, ParameterException, IOException,
ISOException
{
super( params.getParameter( "host" ),
params.getParameterAsInteger( "port" ),
(ISOPackager) man.lookup( "packager" )
);
+ ConfigHelper.initialize( this, man, params );
}
}
\ No newline at end of file
- svn commit: r2105 - development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels, niclas, 03/21/2005
Archive powered by MHonArc 2.6.24.