Package org.silverpeas.processmanager.service

# Class FileContent

java.lang.Object
org.silverpeas.processmanager.service.FileContent

All Implemented Interfaces:
  `Serializable`

public class FileContent extends Object implements Serializable
Object dealing with a file and its content loaded into memory in a array of bytes. A property specifies the original name of the file.

Version:
  $Revision$
Author:
  $Author$
See Also:
  - Serialized Form

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `FileContent()`
  Default constructor.
  `FileContent(String name, byte[] content)`
  Constructor with name and content specifications.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `byte[]`
  `getContent()`
  Return the value of the content property.
  `String`
  `getName()`
  Return the value of the name property.
  `void`
  `setContent(byte[] content)`
  Set the value of the content property.
  `void`
  `setName(String name)`
  Set the value of the name property.
  `String`
  `toString()`

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- ## Constructor Details

  - ### FileContent

    public FileContent()
    Default constructor.

  - ### FileContent

    public FileContent(String name, byte[] content)
    Constructor with name and content specifications.
    Parameters:
      `name` - original name of the file
      `content` - binary data, already loaded, content of the file.

- ## Method Details

  - ### getName

    public String getName()
    Return the value of the name property.
    Returns:
      the value of name.

  - ### setName

    public void setName(String name)
    Set the value of the name property.
    Parameters:
      `name` - the new value of name.

  - ### getContent

    public byte[] getContent()
    Return the value of the content property.
    Returns:
      the value of content (never `null`, may be an empty array).

  - ### setContent

    public void setContent(byte[] content)
    Set the value of the content property.
    Parameters:
      `content` - the new value of content.

  - ### toString

    public String toString()
    Overrides:
      `toString` in class `Object`
    See Also:
      - `Object.toString()`