Migration from Release 2.0 to 4.0.0

This section gives a complete list of API changes in the TL1 product from 2.0 to 4.0.0.

 

Package com.adventnet.tl1

 

Package Changes

 

The table given below lists the package changes made to the class/interfaces.

 

Old Representation

New Representation

com.adventnet.tl1.TL1Parser

com.adventnet.tl1.parser.TL1Parser

 

The table given below lists the static fields that moved from the core (com.adventnet.tl1) to the message package (com.adventnet.tl1.message). These fields are used to identify the type of TL1 message.

 

Fields Moved

Comments

TL1API.INPUT_MESSAGE

These fields are moved to the com.adventnet.tl1.message.TL1Message class.

TL1API.ACK_MESSAGE

TL1API.RESPONSE_MESSAGE

TL1API.AUTONOMOUS_MESSAGE

TL1API.INVALID_MESSAGE

 

API Changes

 

Class

Methods Removed / Changed

Comments

TL1API

start()

This method is used for starting the API thread for monitoring timeout. Since the new API has been designed to be thread configurable, the start() method has been removed. You can configure the thread using the setLoadFactor() and setMaxThread() methods.

addTL1Session(TL1Session)

The adding and deleting of TL1Sessions from the API are done by the TL1API itself while opening and closing the session.

removeTL1Session(TL1Session)

checkResponses()

Equivalent : checkRequests(). Since, it only gives the list of TL1Sessions that have pending requests.

TL1Session

TL1Session(TL1API, Socket)

The following constructors are removed since the TL1 transport is designed to be protocol independent.

TL1Session(TL1API, TL1Parser, Socket)

addTL1Client(TL1Client)

The return type of this method has been changed from void to string. This string is the Client ID string and can be passed to the send method so that the responses for a particular request are given to the client specified by the ClientID instead of all the TL1Clients.

removeTL1Client(TL1Client)

Equivalent : removeTL1Client(String). Here string is the Client ID used to remove a TL1Client from the TL1Session.

open()

Since the client-server communication is through RMI, the following methods are removed.

 

Equivalent : open(Hashtable) method to open the connection.

open(Applet)

open(String, String, Applet)

setProtocolOptions(ProtocolOptions)

Equivalent : open(Hashtable).

getProtocolOptions()

enableTransportProvider(boolean)

Equivalent  : setTransportProvider(TL1TransportProvider).

isSetTransportProvider()

setTransportProviderClassName(String)

getTransportProviderClassName()

checkResponses()

Equivalent : checkRequests(). This method returns an vector containing all pending requests in this session.

receive(String)

Equivalent  : getResponses(String). This method returns a vector of TL1 messages with the same correlation tag.

keepAlive(TL1Message, int)

Equivalent  : setKeepAlive(TL1Message, int).

checkTimeout()

Removed.

setPartialMesgAccumulation(boolean)

Removed since partial messages are no longer supported in TL1 API. But the partial messages are returned to the TL1Client as an timeout response if complete response is not received before the timeout period.

isSetPartialMesgAccumulation()

getTL1ParserOptions()

Removed. The functionality is available from the TL1Session itself.

getLocalHost()

Obsolete. The TL1Sesion layer is designed to be protocol independent.

getLocalPort()

getTargetHost()

getTargetPort()

setIgnoreAutoMsg(boolean)

Removed since autonomous messages are no longer supported in synchronous mechanism.

isIgnoreAutoMsg()

setAppletLogFile(DataOutputStream)

 

getTASClient()

 

 

Package com.adventnet.tl1.transport

 

Package Changes

 

Old Representation

New Representation

com.adventnet.tl1.transport.TcpTransportImpl

com.adventnet.tl1.transport.tcp.TcpTransportImpl

 

API Changes

 

Class

Methods Removed/Changed

Comments

ProtocolOptions

--

Removed.

TL1TransportProvider

open(ProtocolOptions)

ProtocolOptions class has been removed.

 

Equivalent : open(Hashtable) where Hashtable contains the connection parameters.

processControlAction(Properties)

Removed.

TL1TransportPacket

TL1TransportPacket(ProtocolOptions, byte[])

ProtocolOptions class has been removed.

 

Equivalent :

TL1TransportPacket(byte[]).

setProtocolOptions(ProtocolOptions)

getProtocolOptions()

 

Package com.adventnet.tl1.message

 

Classes Removed/Changed

 

Class

Comments

TL1CommandCode

Removed. Use setCommandCode(String) from the InputMessage class to specify the command code.

TL1ParamValue

Removed. Use setParamValue(String) from the TL1Param class to specify the parameter value.

TL1AccessIdentifier

These classes are completely modified and they extend TL1ParamBlock class so as to provide common functionality.

Please refer the Java docs for more details.

TL1GeneralBlock

TL1MessagePayloadBlock

These classes are completely modified and they extend TL1ParamGroup class so as to provide common functionality.

Please refer the Java docs for more details.

TL1Line

 

API Changes

 

Class

Methods Changed

Comments

TL1Message

setSplCharParsing()

These methods are no longer needed since the TL1 Parser has been designed to work in flexible mode.

isSetSplCharParsing()

TL1InputMessage

TL1InputMessage(TL1CommandCode)

TL1CommandCode class has been removed.

 

Equivalent : TL1InputMessage(String) or setCommandCode(String).

TL1InputMessage(TL1CommandCode, TL1AccessIdentifier)

TL1InputMessage(TL1CommandCode, TL1AccessIdentifier, String)

setAppendFrontString(String)

Equivalent : setAppendFront(String)

setAppendEndString(String)

Equivalent : setAppendEnd(String)

TL1AckMessage

TL1AckMessage(String, String)

Equivalent : TL1AckMessage(String). Here ctag has been made optional.

TL1TextBlock

removeTL1Line(TL1Line)

Equivalent : removeTL1Line(TL1ParamGroup) since TL1Line extends TL1ParamGroup. But functionality remains the same.

setText(String)

Obsolete.

TL1Line

addBlock(Vector)

Equivalent : addParameterBlock(TL1ParamBlock). But functionality remains the same.

addParam(TL1Param)

Removed. You can specify the parameters from the TL1ParamBlock class.

setTL1LineType(byte)

Removed. You must set the line type while constructing the TL1Line.

setBlock(Vector)

Equivalent : setParameterBlocks(Vector). But functionality remains the same.

TL1AutoID

TL1AutoID(String)

Equivalent : TL1AutoID(String, String, String) where string represents the alarm code, atag and output code.

TL1Header

TL1Header(String)

Equivalent : TL1Header(String, TL1Param, TL1Param). Here, the date and time are also mandatory.

TL1Date

TL1Date(int,int,int)

Equivalent : TL1Date(byte , int, int, int) where byte represents the parameter type.

TL1Time

TL1Time(int,int,int)

Equivalent : TL1Time(byte,byte,int,int,int) where byte represents the message type and parameter type respectively.

TL1Param

setParamValueString(String)

Equivalent : setParamValue(String). Functionality remains the same.

 



Copyright © 1999-2003, AdventNet Inc. All Rights Reserved.