BrightSide Workbench Full Report + Source Code
org.turro.elephant.download.ContentStream Class Reference

Public Member Functions

 ContentStream (File file)
 
 ContentStream (String fileName, long fileSize)
 
String getAbsolutePath ()
 
String getFileName ()
 
long getFileSize ()
 
InputStream getInputStream () throws FileNotFoundException
 

Protected Member Functions

InputStream doInputStream ()
 

Detailed Description

Author
Lluis TurrĂ³ Cutiller lluis.nosp@m.@tur.nosp@m.ro.or.nosp@m.g

Definition at line 30 of file ContentStream.java.

Constructor & Destructor Documentation

◆ ContentStream() [1/2]

org.turro.elephant.download.ContentStream.ContentStream ( File  file)

Definition at line 36 of file ContentStream.java.

36  {
37  this.file = file;
38  this.fileName = file.getName();
39  this.fileSize = file.length();
40  }

◆ ContentStream() [2/2]

org.turro.elephant.download.ContentStream.ContentStream ( String  fileName,
long  fileSize 
)

Definition at line 42 of file ContentStream.java.

42  {
43  this.file = null;
44  this.fileName = fileName;
45  this.fileSize = fileSize;
46  }

Member Function Documentation

◆ doInputStream()

InputStream org.turro.elephant.download.ContentStream.doInputStream ( )
protected

Definition at line 68 of file ContentStream.java.

68  {
69  throw new UnsupportedOperationException("Not supported yet."); //To change body of generated methods, choose Tools | Templates.
70  }
Here is the caller graph for this function:

◆ getAbsolutePath()

String org.turro.elephant.download.ContentStream.getAbsolutePath ( )

Definition at line 48 of file ContentStream.java.

48  {
49  return file.getAbsolutePath();
50  }
Here is the caller graph for this function:

◆ getFileName()

String org.turro.elephant.download.ContentStream.getFileName ( )

Definition at line 52 of file ContentStream.java.

52  {
53  return fileName;
54  }
Here is the caller graph for this function:

◆ getFileSize()

long org.turro.elephant.download.ContentStream.getFileSize ( )

Definition at line 56 of file ContentStream.java.

56  {
57  return fileSize;
58  }
Here is the caller graph for this function:

◆ getInputStream()

InputStream org.turro.elephant.download.ContentStream.getInputStream ( ) throws FileNotFoundException

Definition at line 60 of file ContentStream.java.

60  {
61  if(file != null) {
62  return new FileInputStream(file);
63  } else {
64  return doInputStream();
65  }
66  }
Here is the call graph for this function:
Here is the caller graph for this function:

The documentation for this class was generated from the following file: