Nuxeo ECM Projects 5.4.3-SNAPSHOT

org.nuxeo.ecm.webapp.clipboard
Class SummaryEntry

java.lang.Object
  extended by org.nuxeo.ecm.webapp.clipboard.SummaryEntry
All Implemented Interfaces:
Serializable, Comparable<SummaryEntry>

public class SummaryEntry
extends Object
implements Comparable<SummaryEntry>, Serializable

An entry present in a Summary. Each entry has a parent, except for the root entry whose parent is null.

Note that SummaryEntry.getPath() can be different than DocumentModel.getPath() since a DocumentModel object can be added many times at different level of the working list.

Author:
Brice Chaffangeon
See Also:
Serialized Form

Constructor Summary
SummaryEntry()
           
SummaryEntry(DocumentModel doc)
           
SummaryEntry(DocumentRef reference)
           
SummaryEntry(String uuid, String title, Date modifiedDate, String filename, String version, SummaryEntry parent)
           
SummaryEntry(String uuid, String title, String modifiedDate, String filename, String version)
           
 
Method Summary
 int compareTo(SummaryEntry o)
           
 boolean equals(Object obj)
           
 String getBullet()
           
 String getCr()
           
 String getDateSeparator()
           
 DocumentRef getDocumentRef()
           
 String getFilename()
           
 String getFileSeparator()
           
 String getMarker()
           
 String getModifiedDate()
           
 SummaryEntry getParent()
           
 String getPath()
          Returns something like /Workspace1/Folder1/File1.
static List<SummaryEntry> getPathList(List<SummaryEntry> pathList, SummaryEntry parentEntry)
          Calls itself recursively to build a list with all entry of the path.
 String getPathSeparator()
           
 String getTitle()
           
 String getUuid()
           
 String getVersion()
           
 String getVersionSepartor()
           
 int hashCode()
           
 boolean hasParent()
           
 void setBullet(String bullet)
           
 void setCr(String cr)
           
 void setDateSeparator(String dateSeparator)
           
 void setDocumentRef(DocumentRef documentRef)
           
 void setFilename(String filename)
           
 void setFileSeparator(String fileSeparator)
           
 void setMarker(String marker)
           
 void setModifiedDate(String modifiedDate)
           
 void setParent(DocumentRef parentRef)
           
 void setParent(SummaryEntry parent)
           
 void setPathSeparator(String pathSeparator)
           
 void setTitle(String title)
           
 void setUuid(String uuid)
           
 void setVersion(String version)
           
 void setVersionSepartor(String versionSepartor)
           
 String toFlatString()
           
 String toString()
           
 String toTreeString()
           
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SummaryEntry

public SummaryEntry(String uuid,
                    String title,
                    String modifiedDate,
                    String filename,
                    String version)

SummaryEntry

public SummaryEntry(String uuid,
                    String title,
                    Date modifiedDate,
                    String filename,
                    String version,
                    SummaryEntry parent)

SummaryEntry

public SummaryEntry(DocumentModel doc)

SummaryEntry

public SummaryEntry(DocumentRef reference)

SummaryEntry

public SummaryEntry()
Method Detail

getUuid

public String getUuid()

setUuid

public void setUuid(String uuid)

getTitle

public String getTitle()

setTitle

public void setTitle(String title)

getModifiedDate

public String getModifiedDate()

setModifiedDate

public void setModifiedDate(String modifiedDate)

getFilename

public String getFilename()

setFilename

public void setFilename(String filename)

getVersion

public String getVersion()

setVersion

public void setVersion(String version)

toFlatString

public String toFlatString()
Returns:
the entry for a flat view

toTreeString

public String toTreeString()
Returns:
the entry for a hierarchical view

toString

public String toString()
Overrides:
toString in class Object

getParent

public SummaryEntry getParent()

setParent

public void setParent(SummaryEntry parent)

setParent

public void setParent(DocumentRef parentRef)

getDocumentRef

public DocumentRef getDocumentRef()

setDocumentRef

public void setDocumentRef(DocumentRef documentRef)

equals

public boolean equals(Object obj)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object

hasParent

public boolean hasParent()

getPathList

public static List<SummaryEntry> getPathList(List<SummaryEntry> pathList,
                                             SummaryEntry parentEntry)
Calls itself recursively to build a list with all entry of the path.

Parameters:
pathList - the list where to add the found path item
parentEntry - is the SummaryEntry to watch
Returns:
all entry in the path for a given entry (parentEntry).

getPath

public String getPath()
Returns something like /Workspace1/Folder1/File1. Is not tied to DocumentModel.getPath()

Returns:
the full path of the SummaryEntry in the summary.

compareTo

public int compareTo(SummaryEntry o)
Specified by:
compareTo in interface Comparable<SummaryEntry>

getMarker

public String getMarker()

setMarker

public void setMarker(String marker)

getBullet

public String getBullet()

setBullet

public void setBullet(String bullet)

getCr

public String getCr()

setCr

public void setCr(String cr)

getPathSeparator

public String getPathSeparator()

setPathSeparator

public void setPathSeparator(String pathSeparator)

getFileSeparator

public String getFileSeparator()

setFileSeparator

public void setFileSeparator(String fileSeparator)

getVersionSepartor

public String getVersionSepartor()

setVersionSepartor

public void setVersionSepartor(String versionSepartor)

getDateSeparator

public String getDateSeparator()

setDateSeparator

public void setDateSeparator(String dateSeparator)

Nuxeo ECM Projects 5.4.3-SNAPSHOT

Copyright © 2011 Nuxeo SAS. All Rights Reserved.