com.ibm.commerce.rfq.commands

Class RFQResponsePattributeAttachmentAddCmdImpl

    • Constructor Detail

      • RFQResponsePattributeAttachmentAddCmdImpl

        public RFQResponsePattributeAttachmentAddCmdImpl()
    • Method Detail

      • setRequestProperties

        public void setRequestProperties(TypedProperty reqParms)
                                  throws ECException
        Calls super.setRequestProperties to retrieve the rfq Id and the attach file content.
        After this, retrieve that attachment description.
        The WebController calls the setRequestProperties method before invoking the execute method in this command.
        Specified by:
        setRequestProperties in interface ControllerCommand
        Overrides:
        setRequestProperties in class AttachmentUploadCmdImpl
        Parameters:
        com.ibm.commerce.datatype.TypedProperty - request parameters
        Throws:
        ECException
        See Also:
        ContollerCommand#setRequestProperties()
      • performExecute

        public void performExecute()
                            throws ECException
        Save the attachment to datastore, and associate the attachment to an RFQ. Calls super.performExecute() for saving Calls TradeAttachmentCreateCmd.execute() for creating the association

        Specified by:
        performExecute in interface ECCommand
        Specified by:
        performExecute in interface com.ibm.websphere.command.TargetableCommand
        Overrides:
        performExecute in class AttachmentUploadCmdImpl
        Throws:
        ECException
        See Also:
        ControllerComand#performExecute
      • validateParameters

        public void validateParameters()
                                throws ECException
        Checks if the RFQ id has been set, and if specified RFQ exist.

        Specified by:
        validateParameters in interface ECCommand
        Overrides:
        validateParameters in class UploadToStreamCmdImpl
        Throws:
        ECException.
        ECException - Thrown with the message ECMessage._ERR_UPLOAD_MISSING_REFCMD when refcmd is missing from the <instance_name>.xml file attachment configuration section. Thrown with the message ECMessage._ERR_UPLOAD_FILECONTENTTYPE_NOTALLOWED when the contenttype of the upload file does not match the file extension. Thrown with the message ECMessage._ERR_UPLOAD_FILETYPE_NOTALLOWED when the file type is not contained in supportedfileextension as specified in the attachment configuration. Thrown with the message ECMessage._ERR_UPLOAD_FILESIZE_TOOBIG when the filesize exceeds the maximum allowable size in the attachment configuration section of the <instance_name>.xml file.