private String getDocumentText ( ) { try { Document document = textComponent . getDocument ( ) ; String text = document . getText ( 0 , document . getLength ( ) ) ; return text ; } catch ( BadLocationException e ) { logger . warning ( e . toString ( ) ) ; return textComponent . getText ( ) ; } }
Return the text of the document of the text component