IBatchNameFormatter interface definition

Following is the definition of the IBatchNameFormatter interface.

using System;	
using System.Collections.Generic;
using System.Text;
using Kofax.KCS.ImportConnector.Messages;

namespace Kofax.KCS.ImportConnector.Scripting
{
 public interface IBatchNameFormatter
 {
 string GetBatchName(ReadonlyMessage[] msg);
 }
}

The ReadonlyMessage[] array contains all the messages that are part of a batch. If it is a single message batch, then the array contains only one message at position 0. All the properties and fields values are read-only. You cannot change any of those values using this interface. You can use any of the defined Kofax Capture variables, such as, "{Sequence Number}". Kofax Capture variables are translated to Kofax Capture values. Refer to the Kofax Capture documentation for more information about Kofax Capture variables.

The returning string from the function is the actual batch name.

If you write custom batch naming scripts, make sure that the batch names are unique, otherwise the batch creation in Kofax Capture will fail.

ReadonlyMessage properties

Property name

Type

Description

Fields

IDictionary <string, string>

The collection of Key-Value - pairs containing field names in the key values and the field values in the value values.

The collection contains the standard message fields listed below and any extension fields if they are defined in Message Connector.

(Message fields are information that Message Connector delivers with each message.

Message extension fields are currently not provided by Message Connector and should not be used. They are reserved for future use.)

Standard message fields are described in the KC Plug-In Help.

DestConfig

Object (Destination Config)

The configuration of the destination to which the message has been redirected. Do NOT modify the properties of this object!