public abstract class DiffElement<T>
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static DiffElement[] |
EMPTY_ARRAY |
Constructor and Description |
---|
DiffElement() |
Modifier and Type | Method and Description |
---|---|
DiffElement<?> |
copyTo(DiffElement<T> container,
java.lang.String relativePath)
Copies element to the container.
|
DiffContent |
createDiffContent(Project project,
ProgressIndicator indicator)
Called in background thread without ReadLock OR in EDT
|
boolean |
delete()
Deletes element
|
java.nio.charset.Charset |
getCharset() |
abstract DiffElement[] |
getChildren() |
abstract byte [] |
getContent()
Returns content data as byte array.
|
java.io.InputStream |
getContentStream() |
java.util.concurrent.Callable<DiffElement<T>> |
getElementChooser(Project project) |
FileType |
getFileType() |
javax.swing.Icon |
getIcon() |
abstract java.lang.String |
getName() |
Navigatable |
getNavigatable(Project project) |
abstract java.lang.String |
getPath() |
java.lang.String |
getPresentableName() |
java.lang.String |
getPresentablePath() |
static java.lang.String |
getSeparator() |
abstract long |
getSize() |
abstract long |
getTimeStamp() |
abstract T |
getValue() |
abstract boolean |
isContainer() |
boolean |
isOperationsEnabled()
Defines is it possible to perform such operations as copy or delete through Diff Panel
|
void |
refresh(boolean userInitiated) |
public static final DiffElement[] EMPTY_ARRAY
public abstract java.lang.String getPath()
public abstract java.lang.String getName()
public java.lang.String getPresentableName()
public java.lang.String getPresentablePath()
public abstract long getSize()
public abstract long getTimeStamp()
public FileType getFileType()
public abstract boolean isContainer()
public abstract DiffElement[] getChildren() throws java.io.IOException
java.io.IOException
public Navigatable getNavigatable(Project project)
public abstract byte [] getContent() throws java.io.IOException
java.io.IOException
- when readingpublic java.io.InputStream getContentStream() throws java.io.IOException
java.io.IOException
public java.nio.charset.Charset getCharset()
public abstract T getValue()
public static java.lang.String getSeparator()
public javax.swing.Icon getIcon()
public DiffContent createDiffContent(Project project, ProgressIndicator indicator) throws DiffRequestProducerException, ProcessCanceledException
public java.util.concurrent.Callable<DiffElement<T>> getElementChooser(Project project)
public boolean isOperationsEnabled()
true
if copy, delete, etc operations are allowed,
false
otherwisepublic DiffElement<?> copyTo(DiffElement<T> container, java.lang.String relativePath)
container
- file directory or other containerrelativePath
- relative path from roottrue
if coping was completed successfully,
false
otherwisepublic boolean delete()
true
if deletion was completed successfully,
false
otherwisepublic void refresh(boolean userInitiated) throws java.io.IOException
java.io.IOException