org.jdom
Class IllegalAddException

java.lang.Object
  |
  +--java.lang.Throwable
        |
        +--java.lang.Exception
              |
              +--java.lang.RuntimeException
                    |
                    +--java.lang.IllegalArgumentException
                          |
                          +--org.jdom.IllegalAddException

public class IllegalAddException
extends IllegalArgumentException

IllegalAddException is thrown when an Element or Attribute is added to a JDOM construct illegally..

Version:
1.0
Author:
Brett McLaughlin
See Also:
Serialized Form

Constructor Summary
IllegalAddException(Document base, Comment added, String reason)
           This will create an Exception indicating that the addition of the Comment supplied as content to the supplied document is not allowed.
IllegalAddException(Document base, DocType added, String reason)
           This will create an Exception indicating that the addition of the DocType to the supplied document is not allowed.
IllegalAddException(Document base, Element added, String reason)
           This will create an Exception indicating that the addition of the Element supplied as a child of the document is not allowed.
IllegalAddException(Document base, ProcessingInstruction added, String reason)
           This will create an Exception indicating that the addition of the ProcessingInstruction supplied as content to the supplied document is not allowed.
IllegalAddException(Element base, Attribute added, String reason)
           This will create an Exception indicating that the addition of the Attribute supplied to the Element supplied is illegal.
IllegalAddException(Element base, Comment added, String reason)
           This will create an Exception indicating that the addition of the Comment supplied as content to the supplied element is not allowed.
IllegalAddException(Element base, Element added, String reason)
           This will create an Exception indicating that the addition of the Element supplied as a child of the supplied parent is not allowed.
IllegalAddException(Element base, EntityRef added, String reason)
           This will create an Exception indicating that the addition of the EntityRef supplied as content to the supplied element is not allowed.
IllegalAddException(Element base, Namespace added, String reason)
           This will create an Exception indicating that the addition of the Namespace to the supplied element is not allowed.
IllegalAddException(Element base, ProcessingInstruction added, String reason)
           This will create an Exception indicating that the addition of the ProcessingInstruction supplied as content to the supplied element is not allowed.
IllegalAddException(String reason)
           This will create an Exception with the specified error message.
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getLocalizedMessage, getMessage, printStackTrace, printStackTrace, printStackTrace, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

IllegalAddException

public IllegalAddException(Element base,
                           Attribute added,
                           String reason)

This will create an Exception indicating that the addition of the Attribute supplied to the Element supplied is illegal.

Parameters:
base - Element that Attribute couldn't be added to
added - Attribute that could not be added
reason - cause for the problem

IllegalAddException

public IllegalAddException(Element base,
                           Element added,
                           String reason)

This will create an Exception indicating that the addition of the Element supplied as a child of the supplied parent is not allowed.

Parameters:
base - Element that the child couldn't be added to
added - Element that could not be added
reason - cause for the problem

IllegalAddException

public IllegalAddException(Document base,
                           Element added,
                           String reason)

This will create an Exception indicating that the addition of the Element supplied as a child of the document is not allowed.


IllegalAddException

public IllegalAddException(Element base,
                           ProcessingInstruction added,
                           String reason)

This will create an Exception indicating that the addition of the ProcessingInstruction supplied as content to the supplied element is not allowed.

Parameters:
base - element that the PI couldn't be added to
added - PI that could not be added
reason - cause for the problem

IllegalAddException

public IllegalAddException(Document base,
                           ProcessingInstruction added,
                           String reason)

This will create an Exception indicating that the addition of the ProcessingInstruction supplied as content to the supplied document is not allowed.

Parameters:
base - document that the PI couldn't be added to
added - PI that could not be added
reason - cause for the problem

IllegalAddException

public IllegalAddException(Element base,
                           Comment added,
                           String reason)

This will create an Exception indicating that the addition of the Comment supplied as content to the supplied element is not allowed.

Parameters:
base - element that the comment couldn't be added to
added - comment that could not be added
reason - cause for the problem

IllegalAddException

public IllegalAddException(Document base,
                           Comment added,
                           String reason)

This will create an Exception indicating that the addition of the Comment supplied as content to the supplied document is not allowed.

Parameters:
base - document that the PI couldn't be added to
added - PI that could not be added
reason - cause for the problem

IllegalAddException

public IllegalAddException(Element base,
                           EntityRef added,
                           String reason)

This will create an Exception indicating that the addition of the EntityRef supplied as content to the supplied element is not allowed.

Parameters:
base - element that the entity couldn't be added to
added - entity reference that could not be added
reason - cause for the problem

IllegalAddException

public IllegalAddException(Element base,
                           Namespace added,
                           String reason)

This will create an Exception indicating that the addition of the Namespace to the supplied element is not allowed.

Parameters:
base - element that the entity couldn't be added to
added - namespace that could not be added
reason - cause for the problem

IllegalAddException

public IllegalAddException(Document base,
                           DocType added,
                           String reason)

This will create an Exception indicating that the addition of the DocType to the supplied document is not allowed.

Parameters:
base - document that the entity couldn't be added to
added - doctype that could not be added
reason - cause for the problem

IllegalAddException

public IllegalAddException(String reason)

This will create an Exception with the specified error message.



Copyright © 2001 Jason Hunter, Brett McLaughlin. All Rights Reserved.