gran.app.adapter.kernel.attachment
Class BaseAttachmentAdapter

java.lang.Object
  extended bygran.app.adapter.kernel.attachment.BaseAttachmentAdapter
All Implemented Interfaces:
Adapter, AttachmentAdapter, KernelAdapter

public class BaseAttachmentAdapter
extends java.lang.Object
implements AttachmentAdapter


Constructor Summary
BaseAttachmentAdapter()
           
 
Method Summary
 boolean buttonClickedImpl(java.lang.String name, com.oreilly.servlet.MultipartRequest multipartRequest, boolean result)
          Check that button clicked.
 void deleteAllAttachmentsImpl(java.lang.String taskid)
          Delete attachment
 void deleteAttachmentsImpl(java.lang.String taskid, com.oreilly.servlet.MultipartRequest multipartRequest)
          Delete attachment
 java.util.Collection getAttachmentsImpl(java.lang.String taskid, java.util.Collection result)
          Get list of attachments
 java.lang.String getDescription()
          Get description of adapter as plain text
 boolean init()
          Initialize adapter.
 void saveAttachmentImpl(java.lang.String taskid, com.oreilly.servlet.MultipartRequest multipartRequest)
          Save attachment
 void saveAttachmentsFromMessageImpl(java.util.Map attaches, java.lang.String userId, java.lang.String taskId)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BaseAttachmentAdapter

public BaseAttachmentAdapter()
Method Detail

init

public boolean init()
Description copied from interface: Adapter
Initialize adapter. TrackStudio calls this method during startup.

Specified by:
init in interface Adapter
Returns:
true when adapter initialized, false otherwise.

getDescription

public java.lang.String getDescription()
Description copied from interface: Adapter
Get description of adapter as plain text

Specified by:
getDescription in interface Adapter

getAttachmentsImpl

public java.util.Collection getAttachmentsImpl(java.lang.String taskid,
                                               java.util.Collection result)
                                        throws gran.exception.GranException
Get list of attachments

Specified by:
getAttachmentsImpl in interface AttachmentAdapter
Throws:
gran.exception.GranException

buttonClickedImpl

public boolean buttonClickedImpl(java.lang.String name,
                                 com.oreilly.servlet.MultipartRequest multipartRequest,
                                 boolean result)
                          throws gran.exception.GranException
Description copied from interface: AttachmentAdapter
Check that button clicked. This method does not relate to attachments, but useful for proccesing of MultipartRequest forms

Specified by:
buttonClickedImpl in interface AttachmentAdapter
Parameters:
name - - button name
Throws:
gran.exception.GranException

deleteAttachmentsImpl

public void deleteAttachmentsImpl(java.lang.String taskid,
                                  com.oreilly.servlet.MultipartRequest multipartRequest)
                           throws gran.exception.GranException
Description copied from interface: AttachmentAdapter
Delete attachment

Specified by:
deleteAttachmentsImpl in interface AttachmentAdapter
Parameters:
taskid - - task
multipartRequest - - contains info about deleted attachments
Throws:
gran.exception.GranException

saveAttachmentImpl

public void saveAttachmentImpl(java.lang.String taskid,
                               com.oreilly.servlet.MultipartRequest multipartRequest)
                        throws gran.exception.GranException
Description copied from interface: AttachmentAdapter
Save attachment

Specified by:
saveAttachmentImpl in interface AttachmentAdapter
Parameters:
taskid - - task
multipartRequest -
Throws:
gran.exception.GranException

deleteAllAttachmentsImpl

public void deleteAllAttachmentsImpl(java.lang.String taskid)
                              throws gran.exception.GranException
Description copied from interface: AttachmentAdapter
Delete attachment

Specified by:
deleteAllAttachmentsImpl in interface AttachmentAdapter
Parameters:
taskid - - task
Throws:
gran.exception.GranException

saveAttachmentsFromMessageImpl

public void saveAttachmentsFromMessageImpl(java.util.Map attaches,
                                           java.lang.String userId,
                                           java.lang.String taskId)
                                    throws gran.exception.GranException
Specified by:
saveAttachmentsFromMessageImpl in interface AttachmentAdapter
Throws:
gran.exception.GranException


Copyright © 2002-2003 TrackStudio, Ltd. All Rights Reserved.