Project Wonder 5.0

er.attachment.model
Class ERPendingAttachment

java.lang.Object
  extended by er.attachment.model.ERPendingAttachment

public class ERPendingAttachment
extends java.lang.Object

ERPendingAttachment is just a convenience wrapper for tracking uploaded file state for later passing into an attachment processor.

Author:
mschrag

Constructor Summary
ERPendingAttachment(java.io.File uploadedFile)
          Constructs an ERPendingAttachment.
ERPendingAttachment(java.io.File uploadedFile, java.lang.String recommendedFilePath)
          Constructs an ERPendingAttachment.
ERPendingAttachment(java.io.File uploadedFile, java.lang.String recommendedFilePath, java.lang.String mimeType)
          Constructs an ERPendingAttachment.
ERPendingAttachment(java.io.File uploadedFile, java.lang.String recommendedFilePath, java.lang.String mimeType, int width, int height, java.lang.String configurationName, java.lang.String ownerID)
          Constructs an ERPendingAttachment.
ERPendingAttachment(java.io.File uploadedFile, java.lang.String recommendedFilePath, java.lang.String mimeType, java.lang.String configurationName, java.lang.String ownerID)
          Constructs an ERPendingAttachment.
 
Method Summary
 java.lang.String configurationName()
          Returns the name of the configuration settings to use for this upload.
 int height()
          Returns the desired height of this attachment.
 boolean isPendingDelete()
          Returns whether or not this attachment should be deleted after import.
 java.lang.String mimeType()
          Returns the mime type (or null if there isn't an explicit one) for this file.
 java.lang.String ownerID()
          Returns the arbitrary string that represents the ID of the "owner" of this attachment (Person.primaryKey, for instance).
 java.lang.String recommendedFileName()
          Returns the cleansed file name recommended by the user during import.
 java.lang.String recommendedFilePath()
          Returns the path recommended by the user during import.
 void setConfigurationName(java.lang.String configurationName)
          Sets the name of the configuration settings to use for this upload.
 void setHeight(int height)
          Sets the desired height of this attachment (or -1 to not specify).
 void setMimeType(java.lang.String mimeType)
          Sets the mime type (or null if there isn't an explicit one) for this file.
 void setOwnerID(java.lang.String ownerID)
          Sets the arbitrary string that represents the ID of the "owner" of this attachment (Person.primaryKey, for instance).
 void setPendingDelete(boolean pendingDelete)
          Sets whether or not this attachment should be deleted after import.
 void setRecommendedFilePath(java.lang.String recommendedFilePath)
          Sets the path recommended by the user during import.
 void setUploadedFile(java.io.File uploadedFile)
          Sets the uploaded temporary file (which will be deleted at the end).
 void setWidth(int width)
          Sets the desired width of this attachment (or -1 to not specify).
 java.lang.String toString()
           
 java.io.File uploadedFile()
          Returns the uploaded temporary file (which will be deleted at the end).
 int width()
          Returns the desired width of this attachment.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ERPendingAttachment

public ERPendingAttachment(java.io.File uploadedFile)
Constructs an ERPendingAttachment.

Parameters:
uploadedFile - the uploaded temporary file (which will be deleted at the end)

ERPendingAttachment

public ERPendingAttachment(java.io.File uploadedFile,
                           java.lang.String recommendedFilePath)
Constructs an ERPendingAttachment.

Parameters:
uploadedFile - the uploaded temporary file (which will be deleted at the end)
recommendedFilePath - the path recommended by the user during import

ERPendingAttachment

public ERPendingAttachment(java.io.File uploadedFile,
                           java.lang.String recommendedFilePath,
                           java.lang.String mimeType)
Constructs an ERPendingAttachment.

Parameters:
uploadedFile - the uploaded temporary file (which will be deleted at the end)
recommendedFilePath - the path recommended by the user during import
mimeType - the mimeType to use (null = guess based on file extension)

ERPendingAttachment

public ERPendingAttachment(java.io.File uploadedFile,
                           java.lang.String recommendedFilePath,
                           java.lang.String mimeType,
                           java.lang.String configurationName,
                           java.lang.String ownerID)
Constructs an ERPendingAttachment.

Parameters:
uploadedFile - the uploaded temporary file (which will be deleted at the end)
recommendedFilePath - the path recommended by the user during import
mimeType - the mimeType to use (null = guess based on file extension)
configurationName - the name of the configuration settings to use for this processor (see top level docs)
ownerID - an arbitrary string that represents the ID of the "owner" of this thumbnail (Person.primaryKey, for instance)

ERPendingAttachment

public ERPendingAttachment(java.io.File uploadedFile,
                           java.lang.String recommendedFilePath,
                           java.lang.String mimeType,
                           int width,
                           int height,
                           java.lang.String configurationName,
                           java.lang.String ownerID)
Constructs an ERPendingAttachment.

Parameters:
uploadedFile - the uploaded temporary file (which will be deleted at the end)
recommendedFilePath - the path recommended by the user during import
mimeType - the mimeType to use (null = guess based on file extension)
width - the desired width of the attachment
height - the desired height of the attachment
configurationName - the name of the configuration settings to use for this processor (see top level docs)
ownerID - an arbitrary string that represents the ID of the "owner" of this thumbnail (Person.primaryKey, for instance)
Method Detail

uploadedFile

public java.io.File uploadedFile()
Returns the uploaded temporary file (which will be deleted at the end).

Returns:
the uploaded temporary file

setUploadedFile

public void setUploadedFile(java.io.File uploadedFile)
Sets the uploaded temporary file (which will be deleted at the end).

Parameters:
uploadedFile - the uploaded temporary file

recommendedFilePath

public java.lang.String recommendedFilePath()
Returns the path recommended by the user during import.

Returns:
the path recommended by the user during import

setRecommendedFilePath

public void setRecommendedFilePath(java.lang.String recommendedFilePath)
Sets the path recommended by the user during import.

Parameters:
recommendedFilePath - the path recommended by the user during import

recommendedFileName

public java.lang.String recommendedFileName()
Returns the cleansed file name recommended by the user during import.

Returns:
the cleansed file name recommended by the user during import

mimeType

public java.lang.String mimeType()
Returns the mime type (or null if there isn't an explicit one) for this file.

Returns:
the mime type (or null if there isn't an explicit one) for this file

setMimeType

public void setMimeType(java.lang.String mimeType)
Sets the mime type (or null if there isn't an explicit one) for this file.

Parameters:
mimeType - the mime type (or null if there isn't an explicit one) for this file

configurationName

public java.lang.String configurationName()
Returns the name of the configuration settings to use for this upload.

Returns:
the name of the configuration settings to use for this upload

setConfigurationName

public void setConfigurationName(java.lang.String configurationName)
Sets the name of the configuration settings to use for this upload.

Parameters:
configurationName - the name of the configuration settings to use for this upload

ownerID

public java.lang.String ownerID()
Returns the arbitrary string that represents the ID of the "owner" of this attachment (Person.primaryKey, for instance).

Returns:
the arbitrary string that represents the ID of the "owner" of this attachment (Person.primaryKey, for instance)

setOwnerID

public void setOwnerID(java.lang.String ownerID)
Sets the arbitrary string that represents the ID of the "owner" of this attachment (Person.primaryKey, for instance).

Parameters:
ownerID - the arbitrary string that represents the ID of the "owner" of this attachment

setPendingDelete

public void setPendingDelete(boolean pendingDelete)
Sets whether or not this attachment should be deleted after import.

Parameters:
pendingDelete - whether or not this attachment should be deleted after import

isPendingDelete

public boolean isPendingDelete()
Returns whether or not this attachment should be deleted after import.

Returns:
whether or not this attachment should be deleted after import

setWidth

public void setWidth(int width)
Sets the desired width of this attachment (or -1 to not specify).

Parameters:
width - the desired width of this attachment

width

public int width()
Returns the desired width of this attachment.

Returns:
the desired width of this attachment

setHeight

public void setHeight(int height)
Sets the desired height of this attachment (or -1 to not specify).

Parameters:
height - the desired height of this attachment

height

public int height()
Returns the desired height of this attachment.

Returns:
the desired height of this attachment

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

Last updated: Tue, Feb 21, 2017 • 05:45 PM CET

Copyright © 2002 – 2007 Project Wonder.