Skip to Content.
Sympa Menu

notify-dpml - svn commit: r2053 - in development/planet/users/niclas/iso8583: . channels channels/parts channels/parts/src channels/parts/src/main channels/parts/src/main/net channels/parts/src/main/net/dpml channels/parts/src/main/net/dpml/iso8583 channels/parts/src/main/net/dpml/iso8583/parts channels/parts/src/main/net/dpml/iso8583/parts/channels

notify-dpml AT lists.ibiblio.org

Subject: DPML Notify

List archive

Chronological Thread  
  • From: niclas AT hedhman.org
  • To: notify-dpml AT lists.ibiblio.org
  • Subject: svn commit: r2053 - in development/planet/users/niclas/iso8583: . channels channels/parts channels/parts/src channels/parts/src/main channels/parts/src/main/net channels/parts/src/main/net/dpml channels/parts/src/main/net/dpml/iso8583 channels/parts/src/main/net/dpml/iso8583/parts channels/parts/src/main/net/dpml/iso8583/parts/channels
  • Date: Sun, 13 Mar 2005 19:43:53 -0500

Author: niclas AT hedhman.org
Date: Sun Mar 13 19:43:52 2005
New Revision: 2053

Added:
development/planet/users/niclas/iso8583/
development/planet/users/niclas/iso8583/build.xml (contents, props
changed)
development/planet/users/niclas/iso8583/channels/
development/planet/users/niclas/iso8583/channels/build.xml (contents,
props changed)
development/planet/users/niclas/iso8583/channels/parts/
development/planet/users/niclas/iso8583/channels/parts/build.xml
(contents, props changed)
development/planet/users/niclas/iso8583/channels/parts/src/
development/planet/users/niclas/iso8583/channels/parts/src/main/
development/planet/users/niclas/iso8583/channels/parts/src/main/net/
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/

development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/

development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/

development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/

development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/AsciiChannel.java
(contents, props changed)

development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/Base24Channel.java
(contents, props changed)

development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/Base24TcpChannel.java
(contents, props changed)

development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/CsChannel.java
(contents, props changed)

development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/LogChannel.java
(contents, props changed)

development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/LoopbackChannel.java
(contents, props changed)

development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/NacChannel.java
(contents, props changed)

development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/NccChannel.java
(contents, props changed)

development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/PadChannel.java
(contents, props changed)

development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/PostChannel.java
(contents, props changed)

development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/RawChannel.java
(contents, props changed)

development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/VapChannel.java
(contents, props changed)

development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/X25Channel.java
(contents, props changed)

development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/XmlChannel.java
(contents, props changed)
development/planet/users/niclas/iso8583/index.xml (contents, props
changed)
Log:
First step into the ISO8583.

Added: development/planet/users/niclas/iso8583/build.xml
==============================================================================
--- (empty file)
+++ development/planet/users/niclas/iso8583/build.xml Sun Mar 13 19:43:52
2005
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+ Copyright 2004 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.
+-->
+
+<project name="dpml-iso8583" default="default" basedir="."
+ xmlns:transit="antlib:net.dpml.transit">
+
+ <transit:import uri="artifact:template:dpml/magic/reactor"/>
+
+</project>

Added: development/planet/users/niclas/iso8583/channels/build.xml
==============================================================================
--- (empty file)
+++ development/planet/users/niclas/iso8583/channels/build.xml Sun Mar 13
19:43:52 2005
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+ Copyright 2004 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.
+-->
+
+<project name="dpml-iso8583-channels" default="default" basedir="."
+ xmlns:transit="antlib:net.dpml.transit">
+
+ <transit:import uri="artifact:template:dpml/magic/reactor"/>
+
+</project>

Added: development/planet/users/niclas/iso8583/channels/parts/build.xml
==============================================================================
--- (empty file)
+++ development/planet/users/niclas/iso8583/channels/parts/build.xml Sun
Mar 13 19:43:52 2005
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+ Copyright 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.
+-->
+
+<project name="dpml-channels-parts" default="install" basedir="."
+ xmlns:transit="antlib:net.dpml.transit"
+>
+
+ <transit:import uri="artifact:template:dpml/magic/standard"/>
+</project>

Added:
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/AsciiChannel.java
==============================================================================
--- (empty file)
+++
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/AsciiChannel.java
Sun Mar 13 19:43:52 2005
@@ -0,0 +1,51 @@
+/*
+* 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 net.dpml.logging.Logger;
+
+import net.dpml.parameters.ParameterException;
+import net.dpml.parameters.Parameters;
+
+import net.dpml.service.ServiceException;
+import net.dpml.service.ServiceManager;
+
+import org.jpos.iso.ISOPackager;
+
+/** Metro Wrapper for the Ascii Channel in JPos.
+ *
+ * @metro.component name="ascii-channel" lifestyle="singleton"
+ * @metro.service type="org.jpos.iso.ISOChannel"
+ * @metro.service type="org.jpos.iso.FilteredChannel"
+ */
+public class AsciiChannel extends org.jpos.iso.channel.ASCIIChannel
+{
+ /**
+ * @metro.logger name="Ascii"
+ * @metro.dependency type="net.dpml.iso8583.Packager" key="packager"
+ */
+ public AsciiChannel( Logger logger, ServiceManager man, Parameters
params )
+ throws ServiceException, ParameterException
+ {
+ super( params.getParameter( "host" ),
+ params.getParameterAsInteger( "port" ),
+ (ISOPackager) man.lookup( "packager" )
+ );
+ }
+}
\ No newline at end of file

Added:
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/Base24Channel.java
==============================================================================
--- (empty file)
+++
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/Base24Channel.java
Sun Mar 13 19:43:52 2005
@@ -0,0 +1,51 @@
+/*
+* 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 net.dpml.logging.Logger;
+
+import net.dpml.parameters.ParameterException;
+import net.dpml.parameters.Parameters;
+
+import net.dpml.service.ServiceException;
+import net.dpml.service.ServiceManager;
+
+import org.jpos.iso.ISOPackager;
+
+/** Metro Wrapper for the BASE24 Channel in JPos.
+ *
+ * @metro.component name="base24-channel" lifestyle="singleton"
+ * @metro.service type="org.jpos.iso.ISOChannel"
+ * @metro.service type="org.jpos.iso.FilteredChannel"
+ */
+public class Base24Channel extends org.jpos.iso.channel.BASE24Channel
+{
+ /**
+ * @metro.logger name="Base24"
+ * @metro.dependency type="net.dpml.iso8583.Packager" key="packager"
+ */
+ public Base24Channel( Logger logger, ServiceManager man, Parameters
params )
+ throws ServiceException, ParameterException
+ {
+ super( params.getParameter( "host" ),
+ params.getParameterAsInteger( "port" ),
+ (ISOPackager) man.lookup( "packager" )
+ );
+ }
+}
\ No newline at end of file

Added:
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/Base24TcpChannel.java
==============================================================================
--- (empty file)
+++
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/Base24TcpChannel.java
Sun Mar 13 19:43:52 2005
@@ -0,0 +1,51 @@
+/*
+* 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 net.dpml.logging.Logger;
+
+import net.dpml.parameters.ParameterException;
+import net.dpml.parameters.Parameters;
+
+import net.dpml.service.ServiceException;
+import net.dpml.service.ServiceManager;
+
+import org.jpos.iso.ISOPackager;
+
+/** Metro Wrapper for the BASE24 TCP Channel in JPos.
+ *
+ * @metro.component name="base24-tcp-channel" lifestyle="singleton"
+ * @metro.service type="org.jpos.iso.ISOChannel"
+ * @metro.service type="org.jpos.iso.FilteredChannel"
+ */
+public class Base24TcpChannel extends org.jpos.iso.channel.BASE24TCPChannel
+{
+ /**
+ * @metro.logger name="Base24Tcp"
+ * @metro.dependency type="net.dpml.iso8583.Packager" key="packager"
+ */
+ public Base24TcpChannel( Logger logger, ServiceManager man, Parameters
params )
+ throws ServiceException, ParameterException
+ {
+ super( params.getParameter( "host" ),
+ params.getParameterAsInteger( "port" ),
+ (ISOPackager) man.lookup( "packager" )
+ );
+ }
+}
\ No newline at end of file

Added:
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/CsChannel.java
==============================================================================
--- (empty file)
+++
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/CsChannel.java
Sun Mar 13 19:43:52 2005
@@ -0,0 +1,51 @@
+/*
+* 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 net.dpml.logging.Logger;
+
+import net.dpml.parameters.ParameterException;
+import net.dpml.parameters.Parameters;
+
+import net.dpml.service.ServiceException;
+import net.dpml.service.ServiceManager;
+
+import org.jpos.iso.ISOPackager;
+
+/** Metro Wrapper for the CS Channel in JPos.
+ *
+ * @metro.component name="cs-channel" lifestyle="singleton"
+ * @metro.service type="org.jpos.iso.ISOChannel"
+ * @metro.service type="org.jpos.iso.FilteredChannel"
+ */
+public class CsChannel extends org.jpos.iso.channel.CSChannel
+{
+ /**
+ * @metro.logger name="CS"
+ * @metro.dependency type="net.dpml.iso8583.Packager" key="packager"
+ */
+ public CsChannel( Logger logger, ServiceManager man, Parameters params )
+ throws ServiceException, ParameterException
+ {
+ super( params.getParameter( "host" ),
+ params.getParameterAsInteger( "port" ),
+ (ISOPackager) man.lookup( "packager" )
+ );
+ }
+}
\ No newline at end of file

Added:
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/LogChannel.java
==============================================================================
--- (empty file)
+++
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/LogChannel.java
Sun Mar 13 19:43:52 2005
@@ -0,0 +1,51 @@
+/*
+* 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 net.dpml.logging.Logger;
+
+import net.dpml.parameters.ParameterException;
+import net.dpml.parameters.Parameters;
+
+import net.dpml.service.ServiceException;
+import net.dpml.service.ServiceManager;
+
+import org.jpos.iso.ISOPackager;
+
+/** Metro Wrapper for the Log Channel in JPos.
+ *
+ * @metro.component name="log-channel" lifestyle="singleton"
+ * @metro.service type="org.jpos.iso.ISOChannel"
+ * @metro.service type="org.jpos.iso.FilteredChannel"
+ */
+public class LogChannel extends org.jpos.iso.channel.LogChannel
+{
+ /**
+ * @metro.logger name="Log"
+ * @metro.dependency type="net.dpml.iso8583.Packager" key="packager"
+ */
+ public LogChannel( Logger logger, ServiceManager man, Parameters params )
+ throws ServiceException, ParameterException
+ {
+ super( params.getParameter( "host" ),
+ params.getParameterAsInteger( "port" ),
+ (ISOPackager) man.lookup( "packager" )
+ );
+ }
+}
\ No newline at end of file

Added:
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/LoopbackChannel.java
==============================================================================
--- (empty file)
+++
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/LoopbackChannel.java
Sun Mar 13 19:43:52 2005
@@ -0,0 +1,38 @@
+/*
+* 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 net.dpml.logging.Logger;
+
+/** Metro Wrapper for the Loopback Channel in JPos.
+ *
+ * @metro.component name="loopback-channel" lifestyle="singleton"
+ * @metro.service type="org.jpos.iso.ISOChannel"
+ * @metro.service type="org.jpos.iso.FilteredChannel"
+ */
+public class LoopbackChannel extends org.jpos.iso.channel.LoopbackChannel
+{
+ /**
+ * @metro.logger name="Loopback"
+ */
+ public LoopbackChannel( Logger logger )
+ {
+ super();
+ }
+}
\ No newline at end of file

Added:
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/NacChannel.java
==============================================================================
--- (empty file)
+++
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/NacChannel.java
Sun Mar 13 19:43:52 2005
@@ -0,0 +1,69 @@
+/*
+* 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.util.StringTokenizer;
+
+import net.dpml.logging.Logger;
+
+import net.dpml.parameters.ParameterException;
+import net.dpml.parameters.Parameters;
+
+import net.dpml.service.ServiceException;
+import net.dpml.service.ServiceManager;
+
+import org.jpos.iso.ISOPackager;
+
+/** Metro Wrapper for the NAC Channel in JPos.
+ *
+ * @metro.component name="nac-channel" lifestyle="singleton"
+ * @metro.service type="org.jpos.iso.ISOChannel"
+ * @metro.service type="org.jpos.iso.FilteredChannel"
+ */
+public class NacChannel extends org.jpos.iso.channel.NACChannel
+{
+ /**
+ * @metro.logger name="NAC"
+ * @metro.dependency type="net.dpml.iso8583.Packager" key="packager"
+ */
+ public NacChannel( Logger logger, ServiceManager man, Parameters params )
+ throws ServiceException, ParameterException
+ {
+ super( params.getParameter( "host" ),
+ params.getParameterAsInteger( "port" ),
+ (ISOPackager) man.lookup( "packager" ),
+ convertByteArray( params )
+ );
+ }
+
+ private static byte[] convertByteArray( Parameters params )
+ throws ParameterException
+ {
+ String values = params.getParameter( "tpdu" );
+ StringTokenizer st = new StringTokenizer( values, ", ", false );
+ int size = st.countTokens();
+ byte[] result = new byte[ size ];
+ for( int i = 0; st.hasMoreTokens(); i++ )
+ {
+ String token = st.nextToken();
+ result[ i ] = Byte.parseByte( token );
+ }
+ return result;
+ }
+}
\ No newline at end of file

Added:
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/NccChannel.java
==============================================================================
--- (empty file)
+++
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/NccChannel.java
Sun Mar 13 19:43:52 2005
@@ -0,0 +1,69 @@
+/*
+* 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.util.StringTokenizer;
+
+import net.dpml.logging.Logger;
+
+import net.dpml.parameters.ParameterException;
+import net.dpml.parameters.Parameters;
+
+import net.dpml.service.ServiceException;
+import net.dpml.service.ServiceManager;
+
+import org.jpos.iso.ISOPackager;
+
+/** Metro Wrapper for the NCC Channel in JPos.
+ *
+ * @metro.component name="ncc-channel" lifestyle="singleton"
+ * @metro.service type="org.jpos.iso.ISOChannel"
+ * @metro.service type="org.jpos.iso.FilteredChannel"
+ */
+public class NccChannel extends org.jpos.iso.channel.NCCChannel
+{
+ /**
+ * @metro.logger name="NCC"
+ * @metro.dependency type="net.dpml.iso8583.Packager" key="packager"
+ */
+ public NccChannel( Logger logger, ServiceManager man, Parameters params )
+ throws ServiceException, ParameterException
+ {
+ super( params.getParameter( "host" ),
+ params.getParameterAsInteger( "port" ),
+ (ISOPackager) man.lookup( "packager" ),
+ convertByteArray( params )
+ );
+ }
+
+ private static byte[] convertByteArray( Parameters params )
+ throws ParameterException
+ {
+ String values = params.getParameter( "tpdu" );
+ StringTokenizer st = new StringTokenizer( values, ", ", false );
+ int size = st.countTokens();
+ byte[] result = new byte[ size ];
+ for( int i = 0; st.hasMoreTokens(); i++ )
+ {
+ String token = st.nextToken();
+ result[ i ] = Byte.parseByte( token );
+ }
+ return result;
+ }
+}
\ No newline at end of file

Added:
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/PadChannel.java
==============================================================================
--- (empty file)
+++
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/PadChannel.java
Sun Mar 13 19:43:52 2005
@@ -0,0 +1,51 @@
+/*
+* 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 net.dpml.logging.Logger;
+
+import net.dpml.parameters.ParameterException;
+import net.dpml.parameters.Parameters;
+
+import net.dpml.service.ServiceException;
+import net.dpml.service.ServiceManager;
+
+import org.jpos.iso.ISOPackager;
+
+/** Metro Wrapper for the x.25 PAD Channel in JPos.
+ *
+ * @metro.component name="pad-channel" lifestyle="singleton"
+ * @metro.service type="org.jpos.iso.ISOChannel"
+ * @metro.service type="org.jpos.iso.FilteredChannel"
+ */
+public class PadChannel extends org.jpos.iso.channel.PADChannel
+{
+ /**
+ * @metro.logger name="PAD"
+ * @metro.dependency type="net.dpml.iso8583.Packager" key="packager"
+ */
+ public PadChannel( Logger logger, ServiceManager man, Parameters params )
+ throws ServiceException, ParameterException
+ {
+ super( params.getParameter( "host" ),
+ params.getParameterAsInteger( "port" ),
+ (ISOPackager) man.lookup( "packager" )
+ );
+ }
+}
\ No newline at end of file

Added:
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/PostChannel.java
==============================================================================
--- (empty file)
+++
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/PostChannel.java
Sun Mar 13 19:43:52 2005
@@ -0,0 +1,51 @@
+/*
+* 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 net.dpml.logging.Logger;
+
+import net.dpml.parameters.ParameterException;
+import net.dpml.parameters.Parameters;
+
+import net.dpml.service.ServiceException;
+import net.dpml.service.ServiceManager;
+
+import org.jpos.iso.ISOPackager;
+
+/** Metro Wrapper for the Post Channel in JPos.
+ *
+ * @metro.component name="post-channel" lifestyle="singleton"
+ * @metro.service type="org.jpos.iso.ISOChannel"
+ * @metro.service type="org.jpos.iso.FilteredChannel"
+ */
+public class PostChannel extends org.jpos.iso.channel.PostChannel
+{
+ /**
+ * @metro.logger name="Post"
+ * @metro.dependency type="net.dpml.iso8583.Packager" key="packager"
+ */
+ public PostChannel( Logger logger, ServiceManager man, Parameters params
)
+ throws ServiceException, ParameterException
+ {
+ super( params.getParameter( "host" ),
+ params.getParameterAsInteger( "port" ),
+ (ISOPackager) man.lookup( "packager" )
+ );
+ }
+}
\ No newline at end of file

Added:
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/RawChannel.java
==============================================================================
--- (empty file)
+++
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/RawChannel.java
Sun Mar 13 19:43:52 2005
@@ -0,0 +1,69 @@
+/*
+* 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.util.StringTokenizer;
+
+import net.dpml.logging.Logger;
+
+import net.dpml.parameters.ParameterException;
+import net.dpml.parameters.Parameters;
+
+import net.dpml.service.ServiceException;
+import net.dpml.service.ServiceManager;
+
+import org.jpos.iso.ISOPackager;
+
+/** Metro Wrapper for the Raw Channel in JPos.
+ *
+ * @metro.component name="raw-channel" lifestyle="singleton"
+ * @metro.service type="org.jpos.iso.ISOChannel"
+ * @metro.service type="org.jpos.iso.FilteredChannel"
+ */
+public class RawChannel extends org.jpos.iso.channel.RawChannel
+{
+ /**
+ * @metro.logger name="NCC"
+ * @metro.dependency type="net.dpml.iso8583.Packager" key="packager"
+ */
+ public RawChannel( Logger logger, ServiceManager man, Parameters params )
+ throws ServiceException, ParameterException
+ {
+ super( params.getParameter( "host" ),
+ params.getParameterAsInteger( "port" ),
+ (ISOPackager) man.lookup( "packager" ),
+ convertByteArray( params )
+ );
+ }
+
+ private static byte[] convertByteArray( Parameters params )
+ throws ParameterException
+ {
+ String values = params.getParameter( "header" );
+ StringTokenizer st = new StringTokenizer( values, ", ", false );
+ int size = st.countTokens();
+ byte[] result = new byte[ size ];
+ for( int i = 0; st.hasMoreTokens(); i++ )
+ {
+ String token = st.nextToken();
+ result[ i ] = Byte.parseByte( token );
+ }
+ return result;
+ }
+}
\ No newline at end of file

Added:
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/VapChannel.java
==============================================================================
--- (empty file)
+++
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/VapChannel.java
Sun Mar 13 19:43:52 2005
@@ -0,0 +1,51 @@
+/*
+* 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 net.dpml.logging.Logger;
+
+import net.dpml.parameters.ParameterException;
+import net.dpml.parameters.Parameters;
+
+import net.dpml.service.ServiceException;
+import net.dpml.service.ServiceManager;
+
+import org.jpos.iso.ISOPackager;
+
+/** Metro Wrapper for the VAP Channel in JPos.
+ *
+ * @metro.component name="vap-channel" lifestyle="singleton"
+ * @metro.service type="org.jpos.iso.ISOChannel"
+ * @metro.service type="org.jpos.iso.FilteredChannel"
+ */
+public class VapChannel extends org.jpos.iso.channel.VAPChannel
+{
+ /**
+ * @metro.logger name="VAP"
+ * @metro.dependency type="net.dpml.iso8583.Packager" key="packager"
+ */
+ public VapChannel( Logger logger, ServiceManager man, Parameters params )
+ throws ServiceException, ParameterException
+ {
+ super( params.getParameter( "host" ),
+ params.getParameterAsInteger( "port" ),
+ (ISOPackager) man.lookup( "packager" )
+ );
+ }
+}
\ No newline at end of file

Added:
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/X25Channel.java
==============================================================================
--- (empty file)
+++
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/X25Channel.java
Sun Mar 13 19:43:52 2005
@@ -0,0 +1,51 @@
+/*
+* 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 net.dpml.logging.Logger;
+
+import net.dpml.parameters.ParameterException;
+import net.dpml.parameters.Parameters;
+
+import net.dpml.service.ServiceException;
+import net.dpml.service.ServiceManager;
+
+import org.jpos.iso.ISOPackager;
+
+/** Metro Wrapper for the x.25 Channel in JPos.
+ *
+ * @metro.component name="x.25-channel" lifestyle="singleton"
+ * @metro.service type="org.jpos.iso.ISOChannel"
+ * @metro.service type="org.jpos.iso.FilteredChannel"
+ */
+public class X25Channel extends org.jpos.iso.channel.X25Channel
+{
+ /**
+ * @metro.logger name="x.25"
+ * @metro.dependency type="net.dpml.iso8583.Packager" key="packager"
+ */
+ public X25Channel( Logger logger, ServiceManager man, Parameters params )
+ throws ServiceException, ParameterException
+ {
+ super( params.getParameter( "host" ),
+ params.getParameterAsInteger( "port" ),
+ (ISOPackager) man.lookup( "packager" )
+ );
+ }
+}
\ No newline at end of file

Added:
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/XmlChannel.java
==============================================================================
--- (empty file)
+++
development/planet/users/niclas/iso8583/channels/parts/src/main/net/dpml/iso8583/parts/channels/XmlChannel.java
Sun Mar 13 19:43:52 2005
@@ -0,0 +1,51 @@
+/*
+* 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 net.dpml.logging.Logger;
+
+import net.dpml.parameters.ParameterException;
+import net.dpml.parameters.Parameters;
+
+import net.dpml.service.ServiceException;
+import net.dpml.service.ServiceManager;
+
+import org.jpos.iso.ISOPackager;
+
+/** Metro Wrapper for the x.25 Channel in JPos.
+ *
+ * @metro.component name="xml-channel" lifestyle="singleton"
+ * @metro.service type="org.jpos.iso.ISOChannel"
+ * @metro.service type="org.jpos.iso.FilteredChannel"
+ */
+public class XmlChannel extends org.jpos.iso.channel.XMLChannel
+{
+ /**
+ * @metro.logger name="XML"
+ * @metro.dependency type="net.dpml.iso8583.Packager" key="packager"
+ */
+ public XmlChannel( Logger logger, ServiceManager man, Parameters params )
+ throws ServiceException, ParameterException
+ {
+ super( params.getParameter( "host" ),
+ params.getParameterAsInteger( "port" ),
+ (ISOPackager) man.lookup( "packager" )
+ );
+ }
+}
\ No newline at end of file

Added: development/planet/users/niclas/iso8583/index.xml
==============================================================================
--- (empty file)
+++ development/planet/users/niclas/iso8583/index.xml Sun Mar 13 19:43:52
2005
@@ -0,0 +1,50 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+ Copyright 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.
+-->
+
+<index>
+ <import uri="artifact:module:dpml/metro/dpml-metro#SNAPSHOT" />
+
+ <resource>
+ <info>
+ <name>jpos</name>
+ <group>jpos</group>
+ <version>1.4.9</version>
+ </info>
+ </resource>
+
+ <project basedir="channels/parts" >
+ <info>
+ <name>dpml-channels-parts</name>
+ <group>dpml/iso8583/channels</group>
+ <version>1.0</version>
+ </info>
+ <dependencies>
+ <include key="jpos" />
+ <include key="dpml-activity-api" />
+ <include key="dpml-logging-api" />
+ <include key="dpml-context-api" />
+ <include key="dpml-parameters-api"/>
+ <include key="dpml-service-api" />
+ </dependencies>
+ <plugins>
+ <include key="dpml-meta-tools" />
+ </plugins>
+ </project>
+
+</index>



  • svn commit: r2053 - in development/planet/users/niclas/iso8583: . channels channels/parts channels/parts/src channels/parts/src/main channels/parts/src/main/net channels/parts/src/main/net/dpml channels/parts/src/main/net/dpml/iso8583 channels/parts/src/main/net/dpml/iso8583/parts channels/parts/src/main/net/dpml/iso8583/parts/channels, niclas, 03/13/2005

Archive powered by MHonArc 2.6.24.

Top of Page