org.apache.myfaces.custom.fileupload
Class UploadedFileDefaultImplBase

java.lang.Object
  extended by org.apache.myfaces.custom.fileupload.UploadedFileDefaultImplBase
All Implemented Interfaces:
java.io.Serializable, UploadedFile
Direct Known Subclasses:
UploadedFileDefaultFileImpl, UploadedFileDefaultMemoryImpl

public abstract class UploadedFileDefaultImplBase
extends java.lang.Object
implements UploadedFile

Version:
$Revision: 472638 $ $Date: 2006-11-08 15:54:13 -0500 (Wed, 08 Nov 2006) $
Author:
Sylvain Vieujot (latest modification by $Author: grantsmith $)
See Also:
Serialized Form

Constructor Summary
protected UploadedFileDefaultImplBase(java.lang.String name, java.lang.String contentType)
           
 
Method Summary
abstract  byte[] getBytes()
          Answer the uploaded file contents.
 java.lang.String getContentType()
           
abstract  java.io.InputStream getInputStream()
          Answer the uploaded file contents input stream
 java.lang.String getName()
           
abstract  long getSize()
          Answer the size of this file.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.apache.myfaces.custom.fileupload.UploadedFile
getStorageStrategy
 

Constructor Detail

UploadedFileDefaultImplBase

protected UploadedFileDefaultImplBase(java.lang.String name,
                                      java.lang.String contentType)
Method Detail

getBytes

public abstract byte[] getBytes()
                         throws java.io.IOException
Answer the uploaded file contents.

Specified by:
getBytes in interface UploadedFile
Returns:
file contents
Throws:
java.io.IOException

getInputStream

public abstract java.io.InputStream getInputStream()
                                            throws java.io.IOException
Answer the uploaded file contents input stream

Specified by:
getInputStream in interface UploadedFile
Returns:
InputStream
Throws:
java.io.IOException

getContentType

public java.lang.String getContentType()
Specified by:
getContentType in interface UploadedFile
Returns:
Returns the _contentType.

getName

public java.lang.String getName()
Specified by:
getName in interface UploadedFile
Returns:
Returns the _name.

getSize

public abstract long getSize()
Answer the size of this file.

Specified by:
getSize in interface UploadedFile
Returns:
long


Copyright © 2011 The Apache Software Foundation. All Rights Reserved.