diff options
author | mkoch <mkoch@138bc75d-0d04-0410-961f-82ee72b054a4> | 2003-03-21 09:18:31 +0000 |
---|---|---|
committer | mkoch <mkoch@138bc75d-0d04-0410-961f-82ee72b054a4> | 2003-03-21 09:18:31 +0000 |
commit | a9768a06b3b09b597d06b038543d1dea3b35cf08 (patch) | |
tree | d95ec68bafbb0d8912496fa08e30ed162f0c53f0 /libjava/javax/swing/text/BadLocationException.java | |
parent | 7e291b5c009226fbfd7c156b20cb763d09b7db6c (diff) | |
download | ppe42-gcc-a9768a06b3b09b597d06b038543d1dea3b35cf08.tar.gz ppe42-gcc-a9768a06b3b09b597d06b038543d1dea3b35cf08.zip |
2003-03-21 Michael Koch <konqueror@gmx.de>
* javax/swing/Action.java
(ACCELERATOR_KEY): New constant.
(ACTION_COMMAND_KEY): Likewise.
(MNEMONIC_KEY): Likewise.
* javax/swing/UnsupportedLookAndFeelException.java
(UnsupportedLookAndFeelException): Must be public.
* javax/swing/WindowConstants.java
(EXIT_ON_CLOSE): New constant.
* javax/swing/text/BadLocationException.java
(offset): New member variable.
(BadLocationException): New implementation, documentation added.
(offsetRequested): New method.
* javax/swing/text/Caret.java:
Reformated.
* javax/swing/text/Document.java:
Reformated.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@64656 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libjava/javax/swing/text/BadLocationException.java')
-rw-r--r-- | libjava/javax/swing/text/BadLocationException.java | 24 |
1 files changed, 21 insertions, 3 deletions
diff --git a/libjava/javax/swing/text/BadLocationException.java b/libjava/javax/swing/text/BadLocationException.java index 81e6cc8dc03..d62ad5465f9 100644 --- a/libjava/javax/swing/text/BadLocationException.java +++ b/libjava/javax/swing/text/BadLocationException.java @@ -40,7 +40,25 @@ package javax.swing.text; public class BadLocationException extends Exception { - BadLocationException() - { - } + int offset; + + /** + * Constructs a <code>BadLocationException</code> + * + * @param str A string indicating what was wrong with the arguments + * @param offset Offset within the document that was requested >= 0 + */ + public BadLocationException (String str, int offset) + { + super (str); + this.offset = offset; + } + + /** + * Returns the offset into the document that was not legal + */ + public int offsetRequested () + { + return offset; + } } |