ccc.domain
Class FileWorkingCopy

java.lang.Object
  extended by ccc.domain.Entity
      extended by ccc.domain.WorkingCopy<File>
          extended by ccc.domain.FileWorkingCopy
All Implemented Interfaces:
Jsonable, java.io.Serializable

public class FileWorkingCopy
extends WorkingCopy<File>

A working copy for file deltas.

Author:
Civic Computing Ltd.
See Also:
Serialized Form

Constructor Summary
protected FileWorkingCopy()
          Constructor: for persistence only.
  FileWorkingCopy(File delta)
          Constructor.
 
Method Summary
 File delta()
          Retrieve the working copy's state.
 void delta(File snapshot)
          Update this working copy.
 java.lang.String getCharset()
          Accessor.
 Data getData()
          Accessor.
 MimeType getMimeType()
          Accessor.
 java.util.Map<java.lang.String,java.lang.String> getProperties()
          Accessor.
 long getSize()
          Accessor.
 boolean isImage()
          Accessor.
 boolean isText()
          
 
Methods inherited from class ccc.domain.Entity
equals, getId, getVersion, hashCode, setId, toJson, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

FileWorkingCopy

protected FileWorkingCopy()
Constructor: for persistence only.


FileWorkingCopy

public FileWorkingCopy(File delta)
Constructor.

Parameters:
delta - The delta describing this working copy's state.
Method Detail

delta

public void delta(File snapshot)
Update this working copy.

Specified by:
delta in class WorkingCopy<File>
Parameters:
snapshot - The delta describing this working copy's state.

delta

public File delta()
Retrieve the working copy's state.

Specified by:
delta in class WorkingCopy<File>
Returns:
A delta describing this working copy's state.

getData

public Data getData()
Accessor.

Returns:
The working copy's data reference.

getMimeType

public MimeType getMimeType()
Accessor.

Returns:
The working copy's mime type.

getSize

public long getSize()
Accessor.

Returns:
The working copy's size, in bytes.

isImage

public boolean isImage()
Accessor.

Returns:
True if the working copy is an image; false otherwise.

getCharset

public java.lang.String getCharset()
Accessor.

Returns:
The working copy's character set.

isText

public boolean isText()


getProperties

public java.util.Map<java.lang.String,java.lang.String> getProperties()
Accessor.

Returns:
Returns the properties.


Copyright © 2010. All Rights Reserved.