|
Extension SDK 9.0.5 | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
A JotCodeElement
is a JotElement
which exists
at any level within a JotFile
. It contains operations common
to such elements.
JotCodeElement
may represent elements existing
in source files, or other storage mediums. Operations pertaining to source
will return error codes if the element is not in a source file.
isSourceElement()
can be used to determine if this element
represents a node in a source file.
Methods that require the underlying element to exist throw a
JotException
. isExistant()
can be used to determine
if the element exists beforehand.
This interface is not intended to be implemented by clients.
Method Summary | |
void |
addPrecedingComment(JotComment comment)
Adds the given comment on a new line, or lines inserted prior to this element. |
boolean |
childrenContainErrors()
|
void |
delete()
Removes this element, and children, from it's parent, and marks it invalid. |
JotFile |
getContainingJotFile()
Retrieves the JotFile that contains this element. |
java.lang.String |
getLeftWhitespace()
Retrieves the consecutive white characters between the end of the previous element and this elements start position. |
int |
getLength()
Retrieves the length of this element. |
java.lang.String |
getRightWhitespace()
Retrieves the consecutive white characters between the end of this element and the start position of the next element. |
boolean |
isInError()
|
boolean |
isSource()
Indicates whether this JotCodeElement instance represents an
element contained by a source file. |
void |
setLeftWhitespace(java.lang.String leftWhitespace)
Sets the consecutive white characters between the end of the previous element and this elements start position. |
void |
setRightWhitespace(java.lang.String rightWhitespace)
Sets the consecutive white characters between the end of this element and the start position of the next element, or the end of the file. |
Methods inherited from interface oracle.jdeveloper.jot.JotElement |
getChildren, getContainedElements, getElementName, getElementType, getEndOffset, getID, getJotWorkArea, getParent, getStartOffset, isExistent, isReadOnly, isStructureKnown, setParent |
Method Detail |
public boolean isSource()
JotCodeElement
instance represents an
element contained by a source file.
JotCodeElement
instance represents a
source file, false otherwise.public int getLength() throws JotInvalidElementException
JotInvalidElementException
public JotFile getContainingJotFile() throws JotInvalidElementException
JotFile
that contains this element.
JotFile
occuring up the parent chain.
JotInvalidElementException
public boolean isInError() throws JotInvalidElementException
JotInvalidElementException
public boolean childrenContainErrors() throws JotInvalidElementException
JotInvalidElementException
public void delete() throws JotInvalidElementException
JotInvalidElementException
public java.lang.String getLeftWhitespace() throws JotInvalidElementException
String
containing the preceding whitespace.
JotInvalidElementException
public java.lang.String getRightWhitespace() throws JotInvalidElementException
String
containing the trailing whitespace.
JotInvalidElementException
public void setLeftWhitespace(java.lang.String leftWhitespace) throws JotInvalidElementException, java.lang.IllegalArgumentException
leftWhitespace
- A String
containing the new preceding
whitespace.
JotInvalidElementException
java.lang.IllegalArgumentException
public void setRightWhitespace(java.lang.String rightWhitespace) throws JotInvalidElementException, java.lang.IllegalArgumentException
rightWhitespace
- A String
containing the new trailing
whitespace.
JotInvalidElementException
java.lang.IllegalArgumentException
public void addPrecedingComment(JotComment comment) throws JotInvalidElementException
JotInvalidElementException
|
Extension SDK | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Copyright © 1997, 2004, Oracle. All rights reserved.