PackagedPayloadsRepository

public class PackagedPayloadsRepository extends PayloadsRepository

The outgoing payloads repository retrieves the payload which is in the form of zip files. Creation Date: 5/10/2006

Author:Twinsen Tsang

Fields

PACKAGE_EXT

public static final String PACKAGE_EXT

The packaged payload extension.

Methods

createPayloads

public NamedPayloads createPayloads(Object[] params, int initialState)

Create a customizing payloads for the specified parameter. Since the packaged payloads is in the form of <partnership_id>$<message_id>, so the size of parameters size should have at least 2.

Parameters:
  • params – An array object parameters set for creating the payload.
Throws:

createPayloadsProxy

protected NamedPayloads createPayloadsProxy(File proxyObj)

Create a customizing payloads for this repository.

Parameters:
  • proxyObj – The file object for the payloads.
Returns:

a customizing payloads.

getPayload

public NamedPayloads getPayload(Object[] params, int state)

Get a particular payload in the payload repository by the specified parameters. Since the outgoing payloads is in the form of <partnership_id>$<message_id>, so the size of parameters size should have at least 2.

Parameters:
  • params – An array object parameters set for creating the payload.
  • state – The current state of that payload.
Returns:

the payload with the specified params or null if it does not exist.

getPayloads

public Collection getPayloads()
Returns:return a set of packaged payload.

getProcessingPayloads

public Collection getProcessingPayloads()
Returns:Get the list of processing payloads in the payload repositoy;

getReadyPayloads

public Collection getReadyPayloads()
Returns:return a set of ready to sent payload

init

protected void init()

Invoke for component initialization.

main

public static void main(String[] args)

toString

public String toString()

toString method