com.npdbhipdb
Class QRXS

java.lang.Object
  extended by com.npdbhipdb.QRXS

public class QRXS
extends java.lang.Object

QRXS API and client implementation.


Nested Class Summary
 class QRXS.Configuration
          QRXS configuration.
 class QRXS.ErrorFile
          Encapsulate processing error file name and associated error code.
(package private) static class QRXS.StatusCodeReference
          Reference class used to associate status codes with their descriptions
 
Constructor Summary
QRXS()
           
 
Method Summary
 java.lang.String changePassword(QRXS.Configuration configuration, java.lang.String password, java.lang.String configFilename, boolean updateConfigFile)
          Perform a change password transaction without a file submission.
 java.lang.String encode(java.lang.String filename, java.lang.String password)
          Encode the password and add to the properties file
 java.lang.String encodeProxyPwd(java.lang.String filename, java.lang.String password)
          Encode the proxy password and add to the properties file
 java.lang.String getNewPassword()
           
 java.lang.String getStatusMessage()
           
 boolean getupdateConfigFile()
           
 java.lang.String getVersion()
          Gets the version.
static void main(java.lang.String[] args)
           
 java.lang.String receive(QRXS.Configuration configuration, java.util.List<java.lang.String> responseFilenames)
          Receive responses from server, save files to download directory
 java.lang.String resetPassword(QRXS.Configuration configuration, java.lang.String user)
          Perform a reset password transaction without a file submission.
 java.lang.String send(QRXS.Configuration configuration, java.util.List<java.lang.String> submissionFilenames, java.util.List<java.lang.String> responseFilenames, java.util.List<QRXS.ErrorFile> errorFiles)
          Perform the send transaction.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

QRXS

public QRXS()
Method Detail

getVersion

public java.lang.String getVersion()
Gets the version.

Returns:
Version Number, as a String.

send

public java.lang.String send(QRXS.Configuration configuration,
                             java.util.List<java.lang.String> submissionFilenames,
                             java.util.List<java.lang.String> responseFilenames,
                             java.util.List<QRXS.ErrorFile> errorFiles)
                      throws QRXSException
Perform the send transaction. Submit upload files, receive error notifications, store responses

Parameters:
configuration - QRXS configuration
submissionFilenames - Paths of files to upload
responseFilenames - File names of response files received into download directory
errorFiles - QRXS.ErrorFile list, Upload files that were rejected outright, no response generated
Returns:
Status code
Throws:
QRXSException - Error sending, receiving, or storing files

receive

public java.lang.String receive(QRXS.Configuration configuration,
                                java.util.List<java.lang.String> responseFilenames)
                         throws QRXSException
Receive responses from server, save files to download directory

Parameters:
configuration - QRXS configuration
responseFilenames - Response filenames received
Returns:
Status code
Throws:
QRXSException - Error receiving or storing files

encode

public java.lang.String encode(java.lang.String filename,
                               java.lang.String password)
                        throws QRXSException
Encode the password and add to the properties file

Parameters:
filename - Properties file name
password - Password to encode
Returns:
C00 if successful
Throws:
QRXSException - Properties file not found

encodeProxyPwd

public java.lang.String encodeProxyPwd(java.lang.String filename,
                                       java.lang.String password)
                                throws QRXSException
Encode the proxy password and add to the properties file

Parameters:
filename - Properties file name
password - Proxy Password to encode
Returns:
C00 if successful
Throws:
QRXSException - Properties file not found

main

public static void main(java.lang.String[] args)

getStatusMessage

public java.lang.String getStatusMessage()
Returns:
Returns the status message.

getupdateConfigFile

public boolean getupdateConfigFile()
Returns:
Should the properties file be updated as a result of a changepassword command

getNewPassword

public java.lang.String getNewPassword()
Returns:
Returns the new password.

resetPassword

public java.lang.String resetPassword(QRXS.Configuration configuration,
                                      java.lang.String user)
                               throws QRXSException
Perform a reset password transaction without a file submission.

Parameters:
configuration - QRXS configuration
user - User whose password needs to get reset
Returns:
Status code
Throws:
QRXSException - Error occurred while resetting password

changePassword

public java.lang.String changePassword(QRXS.Configuration configuration,
                                       java.lang.String password,
                                       java.lang.String configFilename,
                                       boolean updateConfigFile)
                                throws QRXSException
Perform a change password transaction without a file submission.

Parameters:
configuration - QRXS configuration
password - The new password
updateConfigFile - If the config file should be encoded with the new password
configFilename - The config file name
Returns:
Status code
Throws:
QRXSException - Error occurred while changing password