com.sun.im.service
Class SenderFileStreamingProfile

java.lang.Object
  extended bycom.sun.im.service.SenderStreamingProfile
      extended bycom.sun.im.service.SenderFileStreamingProfile

public class SenderFileStreamingProfile
extends SenderStreamingProfile

Author:
Rahul

Constructor Summary
SenderFileStreamingProfile(java.io.File file, boolean computeHash, java.lang.String description)
          Creates a new instance of SenderFileStreamingProfile
 
Method Summary
 java.lang.String getDescription()
          Get the description associated with the stream
 java.io.File getFile()
          Get the file associated with this profile
 byte[] getHash()
          Gets the MD5 hash of the file for the streaming
 void setHash(byte[] hash)
          Sets the MD5 hash of the file for the streaming
 
Methods inherited from class com.sun.im.service.SenderStreamingProfile
getMimeType, setMimeType
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SenderFileStreamingProfile

public SenderFileStreamingProfile(java.io.File file,
                                  boolean computeHash,
                                  java.lang.String description)
                           throws java.io.FileNotFoundException
Creates a new instance of SenderFileStreamingProfile

Parameters:
file - The file which is being streamed
computeHash - Computes the MD5 digest of the file.
description - The description of about the file
Throws:
java.io.FileNotFoundException - when the file passed to it does not exists
Method Detail

getFile

public java.io.File getFile()
Get the file associated with this profile

Returns:
The file associated with the profile

getHash

public byte[] getHash()
Gets the MD5 hash of the file for the streaming

Returns:
The MD5 hash

setHash

public void setHash(byte[] hash)
Sets the MD5 hash of the file for the streaming

Parameters:
hash - The MD5 hash

getDescription

public java.lang.String getDescription()
Get the description associated with the stream

Returns:
Description