com.alee.extended.tab
Class DocumentAdapter<T extends DocumentData>

java.lang.Object
  extended by com.alee.extended.tab.DocumentAdapter<T>
All Implemented Interfaces:
DocumentListener<T>

public abstract class DocumentAdapter<T extends DocumentData>
extends java.lang.Object
implements DocumentListener<T>

Extension for WebDocumentPane documents state listener.

Author:
Mikle Garin
See Also:
How to use WebDocumentPane, WebDocumentPane

Constructor Summary
DocumentAdapter()
           
 
Method Summary
 void closed(T document, PaneData<T> pane, int index)
          Informs that provided document is closed.
 boolean closing(T document, PaneData<T> pane, int index)
          Informs that provided document is being closed.
 void opened(T document, PaneData<T> pane, int index)
          Informs that provided document was opened inside document pane.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DocumentAdapter

public DocumentAdapter()
Method Detail

opened

public void opened(T document,
                   PaneData<T> pane,
                   int index)
Informs that provided document was opened inside document pane.

Specified by:
opened in interface DocumentListener<T extends DocumentData>
Parameters:
document - document data
pane - specific document pane
index - document tab index

closing

public boolean closing(T document,
                       PaneData<T> pane,
                       int index)
Informs that provided document is being closed. Returns whether document is allowed to close or not.

Specified by:
closing in interface DocumentListener<T extends DocumentData>
Parameters:
document - document data
pane - specific document pane
index - document tab index
Returns:
true if document is allowed to close, false otherwise

closed

public void closed(T document,
                   PaneData<T> pane,
                   int index)
Informs that provided document is closed.

Specified by:
closed in interface DocumentListener<T extends DocumentData>
Parameters:
document - document data
pane - specific document pane
index - document tab index