de.schlichtherle.truezip.file.swing
Class TFileView
java.lang.Object
javax.swing.filechooser.FileView
de.schlichtherle.truezip.file.swing.TDecoratingFileView
de.schlichtherle.truezip.file.swing.TFileView
@DefaultAnnotation(value=edu.umd.cs.findbugs.annotations.NonNull.class)
public class TFileView
- extends TDecoratingFileView
An archive enabled file view.
This class recognizes instances of the TFile class and returns
custom icons and type descriptions if it's an archive file or an archive
entry.
Otherwise, the super class behaviour is used.
Note that this class accesses archive files lazily, i.e. it does not
eagerly check the true status with TFile.isDirectory() or similar
unless really necessary. This is to prevent dead locks between the Event
Dispatch Thread and the Basic L&F TFile Loading Threads which are forked
by JFileChooser.
- Author:
- Christian Schlichtherle
|
Constructor Summary |
TFileView(FileView fileView)
Creates a new archive enabled file view. |
CLASS_NAME
private static final String CLASS_NAME
resources
private static final ResourceBundle resources
TFileView
public TFileView(@CheckForNull
FileView fileView)
- Creates a new archive enabled file view.
- Parameters:
fileView - The nullable file view to decorate.
getTypeDescription
@Nullable
public String getTypeDescription(File file)
- Overrides:
getTypeDescription in class TDecoratingFileView
typeDescription
@Nullable
static String typeDescription(File file)
getIcon
@Nullable
public Icon getIcon(File file)
- Overrides:
getIcon in class TDecoratingFileView
icon
@Nullable
static Icon icon(File file)
isTrueArchive
private static boolean isTrueArchive(TFile file)
newNonArchiveFile
private static TFile newNonArchiveFile(@NonNull
TFile file)
isEntryInTrueArchive
private static boolean isEntryInTrueArchive(TFile file)
isTraversable
@Nullable
public Boolean isTraversable(File file)
- Overrides:
isTraversable in class TDecoratingFileView
Copyright © 2005-2011 Schlichtherle IT Services. All Rights Reserved.