|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectedu.washington.biostr.sig.vault.files.AllTypes
public class AllTypes
| Field Summary |
|---|
| Fields inherited from interface edu.washington.biostr.sig.vault.files.FileType |
|---|
ACCEPTABLE, DISCOURAGED, PREFERRED |
| Constructor Summary | |
|---|---|
AllTypes()
|
|
| Method Summary | |
|---|---|
boolean |
accept(FileType other)
|
URI[] |
accept(SortedSet<URI> files,
URI filename)
Return the fileset if the given name is acceptable and it exists in the specified directory. |
boolean |
accept(URI[] group)
|
int |
compareTo(FileType o)
This equals AllType's, is larger than all FileType's |
URI[] |
generateFiles(URI filename)
Create full filenames from the given filename. |
Icon |
getDefaultIcon(String file)
A filetype can optionally have an icon. |
String |
getExtension(int extensionNum)
|
int |
getPreference()
Return PREFERRED, ACCEPTABLE (default) or DISCOURAGED. |
int |
getSortingSpot()
To ensure that nodes are comparable across different types, when comparing different types, simply return:
int value = getSortingSpot() - other.getSortingSpot(); |
FileType |
getType(URI[] group)
If this type supports subtypes, get the subtype for this group. |
boolean |
isDecodable()
|
boolean |
isEncodable()
|
URI[] |
next(SortedSet<URI> files)
Get the next set of files that match this type and remove them from files. |
String |
toString(FileGroup group)
Get the preferred string for this group. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public AllTypes()
| Method Detail |
|---|
public boolean accept(FileType other)
accept in interface FileTypepublic boolean accept(URI[] group)
accept in interface FileTypepublic URI[] next(SortedSet<URI> files)
FileType
next in interface FileTypefiles - An list of files alphabatized using String's compareTo method.
public Icon getDefaultIcon(String file)
FileType
getDefaultIcon in interface FileTypepublic FileType getType(URI[] group)
FileType
getType in interface FileTypepublic URI[] generateFiles(URI filename)
FileType
generateFiles in interface FileTypepublic int compareTo(FileType o)
compareTo in interface Comparable<FileType>Comparable.compareTo(java.lang.Object)public int getSortingSpot()
FileType
int value = getSortingSpot() - other.getSortingSpot();
if (value == 0)
{
value = toString().compareTo(other.toString());
if (value == 0)
{
return getClass().getName().compareTo(other.getClass().getName());
}
}
return value;
- Specified by:
getSortingSpot in interface FileType
- Returns:
- 120321430
public URI[] accept(SortedSet<URI> files,
URI filename)
FileType
accept in interface FileTypepublic int getPreference()
FileType
getPreference in interface FileTypepublic String toString(FileGroup group)
FileType
toString in interface FileTypepublic boolean isDecodable()
isDecodable in interface FileTypepublic boolean isEncodable()
isEncodable in interface FileTypepublic String getExtension(int extensionNum)
getExtension in interface FileType
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||