Package com.uc4.util
Class FolderImpl
- java.lang.Object
-
- com.uc4.util.FolderImpl
-
-
Constructor Summary
Constructors Constructor Description FolderImpl(java.lang.String name, java.lang.String title, java.lang.String id, java.lang.String parentId, java.lang.String type)
Constructs a new folder using the specified name, id and parent id.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addChild(FolderImpl folder)
Adds a child to this folderboolean
equals(java.lang.Object other)
java.lang.String
fullPath()
Returns the full path of this folder.java.lang.String
getId()
Returns the ID of the folder.java.lang.String
getName()
Returns the name of the folder.IFolder
getParent()
Returns the parent folder of this folder.java.lang.String
getParentId()
Returns the ID of the parent folder.IFolder
getSubFolder(java.lang.String folderName, boolean recursive)
Returns a subfolder with the specified name.java.lang.String
getTitle()
Returns the title of the folder.java.lang.String
getType()
Returns the type of this folder CLNT ...int
hashCode()
void
setParent(IFolder parent)
Sets the parent folderjava.util.Iterator<IFolder>
subfolder()
Returns an iterator for subfolders Each object in the list implements theIFolder
interface.java.lang.String
toString()
-
-
-
Constructor Detail
-
FolderImpl
public FolderImpl(java.lang.String name, java.lang.String title, java.lang.String id, java.lang.String parentId, java.lang.String type)
Constructs a new folder using the specified name, id and parent id.- Parameters:
name
- Name of the foldertitle
- Title of the folderid
- String containing the ID of the folderparentId
- String containing the ID of the parent foldertype
- Type of the folder
-
-
Method Detail
-
addChild
public void addChild(FolderImpl folder)
Adds a child to this folder- Parameters:
folder
- Folder which sould be added as child
-
getId
public java.lang.String getId()
Description copied from interface:IFolder
Returns the ID of the folder.
-
getName
public java.lang.String getName()
Description copied from interface:IFolder
Returns the name of the folder.
-
getTitle
public java.lang.String getTitle()
Description copied from interface:IFolder
Returns the title of the folder.
-
getParentId
public java.lang.String getParentId()
Returns the ID of the parent folder.- Returns:
- String containing the ID of the parent folder
-
setParent
public void setParent(IFolder parent)
Sets the parent folder- Parameters:
parent
- Parent folder
-
equals
public boolean equals(java.lang.Object other)
- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
getSubFolder
public IFolder getSubFolder(java.lang.String folderName, boolean recursive)
Description copied from interface:IFolder
Returns a subfolder with the specified name.- Specified by:
getSubFolder
in interfaceIFolder
- Parameters:
folderName
- Name of the subfolderrecursive
-true
if recursivefalse
otherwise- Returns:
- object which implements
IFolder
-
subfolder
public java.util.Iterator<IFolder> subfolder()
Description copied from interface:IFolder
Returns an iterator for subfolders Each object in the list implements theIFolder
interface. If there are no subfolders this method returnsnull
.
-
getParent
public IFolder getParent()
Description copied from interface:IFolder
Returns the parent folder of this folder.
-
fullPath
public java.lang.String fullPath()
Description copied from interface:IFolder
Returns the full path of this folder. Each folder is separated by a /
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
getType
public java.lang.String getType()
Description copied from interface:IFolder
Returns the type of this folder- CLNT ... Client, Root folder, exists only once
- NFOLD ... No Folder, exists only once
- FAV ... Favorites folder, exists only once
- USERF ... User favorites
- USRGF ... User Group favorites
- TRANSCASE ... Transport folder
- VERSCONTROL ... Version Management folder
- RCNT ... Recent Objects
- TRASH ... Recycle Bin
- FOLD ... Normal folder
-
-