|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
org.nuiton.widget.ApplicationMonitor
public class ApplicationMonitor
| Nested Class Summary | |
|---|---|
protected class |
ApplicationMonitor.LogListener
|
| Nested classes/interfaces inherited from class javax.swing.JPanel |
|---|
javax.swing.JPanel.AccessibleJPanel |
| Nested classes/interfaces inherited from class javax.swing.JComponent |
|---|
javax.swing.JComponent.AccessibleJComponent |
| Nested classes/interfaces inherited from class java.awt.Container |
|---|
java.awt.Container.AccessibleAWTContainer |
| Nested classes/interfaces inherited from class java.awt.Component |
|---|
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BaselineResizeBehavior, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy |
| Field Summary | |
|---|---|
protected javax.swing.JTextArea |
allStreamsTextArea
|
static int |
DEFAULT_FOOTER_LINE
nombre de ligne a conserver en fin des logs ex: stack trace si egal a -1 en meme temps que DEFAULT_HEADER_LINE alors tout le log est conservé |
static java.lang.String |
DEFAULT_FROM_ADDRESS
|
static int |
DEFAULT_HEADER_LINE
nombre de ligne a conserver au debut des logs ex: param de lancement si egal a -1 en meme temps que DEFAULT_FOOTER_LINE alors tout le log est conservé |
static java.lang.String |
DEFAULT_LOGGING_SYSTEM
|
static java.lang.String |
DEFAULT_SMTP_SERVER
|
static java.lang.String |
DEFAULT_TO_ADDRESS
|
protected javax.swing.JTextArea |
errorStreamTextArea
|
protected java.lang.String |
from
|
protected javax.swing.JPanel |
jPanel
|
protected javax.swing.JPanel |
jPanel1
|
protected javax.swing.JPanel |
jPanel2
|
protected javax.swing.JPanel |
jPanel2bis
|
protected javax.swing.JPanel |
jPanel3
|
protected javax.swing.JPanel |
jPanel4
|
protected javax.swing.JPanel |
jPanel5
|
protected javax.swing.JPanel |
jPanel6
|
protected javax.swing.JScrollPane |
jScrollPane
|
protected javax.swing.JScrollPane |
jScrollPane1
|
protected javax.swing.JScrollPane |
jScrollPane2
|
protected javax.swing.JScrollPane |
jScrollPanebis
|
protected javax.swing.JTabbedPane |
jTabbedPane
|
protected java.lang.String |
loggingSystem
|
protected ApplicationMonitor.LogListener |
logListener
|
protected javax.swing.JTextArea |
logStreamTextArea
|
protected javax.swing.JTextArea |
outputStreamTextArea
|
protected javax.swing.JButton |
resetButton
|
protected javax.swing.JButton |
sendByEmailButton
|
protected java.lang.String |
smtpServer
|
protected StatusBar |
statusBar
|
protected java.io.PrintStream |
stderr
|
protected java.io.PrintStream |
stdout
|
protected java.lang.String |
to
|
| Fields inherited from class javax.swing.JComponent |
|---|
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
| Fields inherited from class java.awt.Component |
|---|
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
| Fields inherited from interface java.awt.image.ImageObserver |
|---|
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
| Constructor Summary | |
|---|---|
ApplicationMonitor()
This is the default constructor |
|
ApplicationMonitor(java.lang.String loggingSystem)
|
|
ApplicationMonitor(java.lang.String loggingSystem,
java.lang.String smtpServer,
java.lang.String from,
java.lang.String to)
|
|
| Method Summary | |
|---|---|
protected void |
ensureLine(javax.swing.JTextArea target)
ensure that the textarea does'nt have more than necessary line |
protected void |
finalize()
|
protected javax.swing.JTextArea |
getAllStreamsTextArea()
This method initializes allStreamsTextArea |
protected javax.swing.JTextArea |
getErrorStreamTextArea()
This method initializes jTextArea1 |
protected javax.swing.JPanel |
getJPanel()
This method initializes jPanel |
protected javax.swing.JPanel |
getJPanel1()
This method initializes jPanel1 |
protected javax.swing.JPanel |
getJPanel2()
This method initializes jPanel2 |
protected javax.swing.JPanel |
getJPanel2bis()
This method initializes jPanel2bis |
protected javax.swing.JPanel |
getJPanel3()
This method initializes jPanel3 |
protected javax.swing.JPanel |
getJPanel4()
This method initializes jPanel4 |
protected javax.swing.JPanel |
getJPanel5()
This method initializes jPanel5 |
protected javax.swing.JPanel |
getJPanel6()
This method initializes jPanel6 |
protected javax.swing.JScrollPane |
getJScrollPane()
This method initializes jScrollPane |
protected javax.swing.JScrollPane |
getJScrollPane1()
This method initializes jScrollPane1 |
protected javax.swing.JScrollPane |
getJScrollPane2()
This method initializes jScrollPane2 |
protected javax.swing.JScrollPane |
getJScrollPanebis()
This method initializes jScrollPanebis |
protected javax.swing.JTabbedPane |
getJTabbedPane()
This method initializes jTabbedPane |
protected javax.swing.JTextArea |
getLogStreamTextArea()
This method initializes jTextArea |
protected javax.swing.JTextArea |
getOutputStreamTextArea()
This method initializes jTextArea |
protected javax.swing.JButton |
getResetButton()
This method initializes jButton |
protected javax.swing.JButton |
getSendByEmailButton()
This method initializes jButton1 |
protected StatusBar |
getStatusBar()
|
protected void |
initialize()
|
protected void |
initializeLoggingHandler()
Set a logging handler up |
protected void |
initializeRedirect()
Sets new OutputStreams for System.out and System.err |
protected void |
initializeUI()
This method initializes UI |
static void |
main(java.lang.String[] args)
|
void |
resetConsoleContent()
|
protected void |
send(java.lang.String smtpServer,
java.lang.String to,
java.lang.String from,
java.lang.String subject,
java.lang.String body)
Send an email using the given informations (stmpServer, toAddress, fromAddress, subject and body). |
void |
sendConsoleContentByMail()
|
void |
setEmailFrom(java.lang.String from)
|
void |
setEmailTo(java.lang.String to)
|
void |
setSmtpServer(java.lang.String smtpServer)
|
| Methods inherited from class javax.swing.JPanel |
|---|
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI |
| Methods inherited from class javax.swing.JComponent |
|---|
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update |
| Methods inherited from class java.awt.Container |
|---|
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate, validateTree |
| Methods inherited from class java.awt.Component |
|---|
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static int DEFAULT_HEADER_LINE
public static int DEFAULT_FOOTER_LINE
public static final java.lang.String DEFAULT_LOGGING_SYSTEM
public static final java.lang.String DEFAULT_SMTP_SERVER
public static final java.lang.String DEFAULT_FROM_ADDRESS
public static final java.lang.String DEFAULT_TO_ADDRESS
protected java.lang.String loggingSystem
protected java.lang.String smtpServer
protected java.lang.String to
protected java.lang.String from
protected java.io.PrintStream stdout
protected java.io.PrintStream stderr
protected ApplicationMonitor.LogListener logListener
protected javax.swing.JPanel jPanel
protected javax.swing.JPanel jPanel1
protected javax.swing.JButton resetButton
protected javax.swing.JButton sendByEmailButton
protected javax.swing.JTabbedPane jTabbedPane
protected javax.swing.JPanel jPanel2
protected javax.swing.JPanel jPanel2bis
protected javax.swing.JPanel jPanel3
protected javax.swing.JScrollPane jScrollPane
protected javax.swing.JScrollPane jScrollPanebis
protected javax.swing.JTextArea outputStreamTextArea
protected javax.swing.JTextArea allStreamsTextArea
protected javax.swing.JScrollPane jScrollPane1
protected javax.swing.JTextArea errorStreamTextArea
protected StatusBar statusBar
protected javax.swing.JPanel jPanel4
protected javax.swing.JScrollPane jScrollPane2
protected javax.swing.JTextArea logStreamTextArea
protected javax.swing.JPanel jPanel5
protected javax.swing.JPanel jPanel6
| Constructor Detail |
|---|
public ApplicationMonitor()
public ApplicationMonitor(java.lang.String loggingSystem)
public ApplicationMonitor(java.lang.String loggingSystem,
java.lang.String smtpServer,
java.lang.String from,
java.lang.String to)
| Method Detail |
|---|
public void resetConsoleContent()
public void sendConsoleContentByMail()
public void setSmtpServer(java.lang.String smtpServer)
smtpServer - the smtpServer to setpublic void setEmailTo(java.lang.String to)
to - the to to setpublic void setEmailFrom(java.lang.String from)
from - the from to setprotected void initialize()
protected void initializeRedirect()
protected void finalize()
throws java.lang.Throwable
finalize in class java.lang.Objectjava.lang.Throwableprotected void initializeLoggingHandler()
protected void send(java.lang.String smtpServer,
java.lang.String to,
java.lang.String from,
java.lang.String subject,
java.lang.String body)
throws javax.mail.internet.AddressException,
javax.mail.MessagingException
smtpServer - to - from - subject - body -
javax.mail.MessagingException
javax.mail.internet.AddressExceptionprotected void initializeUI()
protected javax.swing.JPanel getJPanel()
protected javax.swing.JPanel getJPanel1()
protected javax.swing.JButton getResetButton()
protected javax.swing.JButton getSendByEmailButton()
protected javax.swing.JTabbedPane getJTabbedPane()
protected javax.swing.JPanel getJPanel2bis()
protected javax.swing.JPanel getJPanel2()
protected javax.swing.JPanel getJPanel3()
protected javax.swing.JScrollPane getJScrollPanebis()
protected javax.swing.JScrollPane getJScrollPane()
protected javax.swing.JTextArea getAllStreamsTextArea()
protected javax.swing.JTextArea getOutputStreamTextArea()
protected javax.swing.JScrollPane getJScrollPane1()
protected javax.swing.JTextArea getErrorStreamTextArea()
protected javax.swing.JPanel getJPanel4()
protected javax.swing.JScrollPane getJScrollPane2()
protected javax.swing.JTextArea getLogStreamTextArea()
protected javax.swing.JPanel getJPanel5()
protected javax.swing.JPanel getJPanel6()
protected StatusBar getStatusBar()
protected void ensureLine(javax.swing.JTextArea target)
target - public static void main(java.lang.String[] args)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||