Custom file splitting

You can implement a custom class containing the splitting logic. The adapter provides a Java™ interface for the class. WebSphere® Adapter for FTP, version 7.5 supports additional splitting methods for the inbound process. Hence, there are two different interfaces available for the inbound and outbound process.

Interface for outbound operations

Use the com.ibm.j2ca.utils.filesplit.SplittingFunctionalityInterface interface for the outbound operations.

Following are the details of the interface:

public interface SplittingFunctionalityInterface extends Iterator{
		public int getTotalBOs(String filename) throws SplittingException;
public void setBODetails(String filename, int currentPosition, int totalBOs,
  boolean includeEndBODelimiter) throws SplittingException;
	 	public void setSplitCriteria(String splitCriteria);
	 	public void setEncoding(String encoding);
	 	public void setLogUtils(LogUtils logUtils);
public boolean isSplitBySize()
}

Interface for inbound operations

Use the com.ibm.j2ca.utils.filesplit.InboundSplittingFunctionalityInterface interface for the inbound operations.
Note: The custom splitting class for an inbound operation created in the earlier version of the adapter does not work with version 7.5.

Following are the details of the interface:

public interface InboundSplittingFunctionalityInterface{	
	public Hashtable getBOs(String filename,int quantity, long lastBO,long lastBOPos,boolean withDelim) throws SplittingException,MissingDataException; 
	public void setBODetails(String filename, long currentBO, long startPos, long endPos) throws SplittingException;
	public Object getBOContent();
	public boolean hasMoreBO();
	public void remove();
	public void setSplitCriteria(String splitCriteria);
	public void setEncoding(String encoding);
	public void setLogUtils(LogUtils logUtils);
	public boolean isSplitBySize();
}



Feedback

(C) Copyright IBM Corporation 2005, 2012. All Rights Reserved.
This information center is powered by Eclipse technology. (http://www.eclipse.org)