org.silverpeas.process.io.file
Class DummyFile

java.lang.Object
  extended by org.silverpeas.process.io.file.AbstractDummyHandledFile
      extended by org.silverpeas.process.io.file.DummyFile
All Implemented Interfaces:
DummyHandledFile

public class DummyFile
extends AbstractDummyHandledFile

Simple dummy representation of a File that has to be handle.

User: Yohann Chastagnier Date: 17/10/13


Constructor Summary
DummyFile(File file, String componentInstanceId)
          Case of the file is considered as a creation.
DummyFile(File file, String componentInstanceId, boolean deleted)
          Default constructor.
 
Method Summary
 String getComponentInstanceId()
          Gets the component instance id at which the virtual file is associated.
 String getMimeType()
          Gets the mime type of the virtual file.
 String getName()
          Gets the name of the virtual file.
 String getPath()
          Gets the path of the virtual file.
 long getSize()
          Gets the size of the virtual file (bytes).
 boolean isDeleted()
          Indicates if the virtual file is a deleted one.
 
Methods inherited from class org.silverpeas.process.io.file.AbstractDummyHandledFile
equals, hashCode
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DummyFile

public DummyFile(File file,
                 String componentInstanceId)
Case of the file is considered as a creation.

Parameters:
file -
componentInstanceId -

DummyFile

public DummyFile(File file,
                 String componentInstanceId,
                 boolean deleted)
Default constructor.

Parameters:
file -
deleted -
Method Detail

getComponentInstanceId

public String getComponentInstanceId()
Description copied from interface: DummyHandledFile
Gets the component instance id at which the virtual file is associated.

Returns:

getPath

public String getPath()
Description copied from interface: DummyHandledFile
Gets the path of the virtual file. In most of cases, this information is the same as the name one.

Returns:

getName

public String getName()
Description copied from interface: DummyHandledFile
Gets the name of the virtual file.

Returns:

getSize

public long getSize()
Description copied from interface: DummyHandledFile
Gets the size of the virtual file (bytes).

Returns:

getMimeType

public String getMimeType()
Description copied from interface: DummyHandledFile
Gets the mime type of the virtual file.


isDeleted

public boolean isDeleted()
Description copied from interface: DummyHandledFile
Indicates if the virtual file is a deleted one.

Specified by:
isDeleted in interface DummyHandledFile
Overrides:
isDeleted in class AbstractDummyHandledFile
Returns:


Copyright © 2016 Silverpeas. All Rights Reserved.