java.io.Serializable
, java.lang.Cloneable
, javax.swing.tree.TreeNode
, SBase
, TreeNodeWithChangeSupport
CubicBezier
public class LineSegment extends CurveSegment
LineSegment
class consists of the mandatory attribute xsi:type and two child
elements of type Point
. One is called 'start' and represents the starting point
of the line, the other is called 'end' and represents the endpoint of the line. The
LineSegment
class is also the base class for CubicBezier
, which represent
curved lines instead of straight ones.CurveSegment.Type
JSBML_WRONG_SBO_TERM
Constructor | Description |
---|---|
LineSegment() |
|
LineSegment(int level,
int version) |
|
LineSegment(CurveSegment lineSegment) |
|
LineSegment(LineSegment lineSegment) |
Modifier and Type | Method | Description |
---|---|---|
LineSegment |
clone() |
Creates a deep copy of this object, i.e., a new
SBase with the same
properties
like this one. |
Point |
createEnd() |
Creates, sets and returns a
Point |
Point |
createEnd(double x,
double y,
double z) |
Creates, sets and returns a
Point based on the
given values. |
Point |
createStart() |
Creates, sets and returns a
Point |
Point |
createStart(double x,
double y,
double z) |
Creates, sets and returns a
Point based on the
given values. |
boolean |
equals(java.lang.Object object) |
|
javax.swing.tree.TreeNode |
getChildAt(int index) |
|
int |
getChildCount() |
|
Point |
getEnd() |
|
Point |
getStart() |
|
int |
hashCode() |
Returns a hash code value for this
SBase instance. |
boolean |
isSetEnd() |
|
boolean |
isSetStart() |
|
void |
setEnd(Point end) |
|
void |
setStart(Point start) |
|
void |
unsetEnd() |
Unsets the end-point of this
LineSegment |
void |
unsetStart() |
Unsets the start-point of this
LineSegment |
addCVTerm, addDeclaredNamespace, addExtension, addPlugin, addResources, appendAnnotation, appendAnnotation, appendNotes, appendNotes, createHistory, createPlugin, disablePackage, enablePackage, enablePackage, filterCVTerms, filterCVTerms, filterCVTerms, filterCVTerms, fireNodeRemovedEvent, firePropertyChange, getAllDeclaredNamespaces, getAllowsChildren, getAnnotation, getAnnotationString, getCVTerm, getCVTermCount, getCVTerms, getDeclaredNamespaces, getElementByMetaId, getElementBySId, getElementName, getExtension, getExtensionCount, getExtensionPackages, getFirstElementIndex, getHistory, getId, getLevel, getLevelAndVersion, getMetaId, getModel, getName, getNamespace, getNotes, getNotesString, getNumCVTerms, getNumPlugins, getPackageName, getPackageVersion, getParent, getParentSBMLObject, getPlugin, getSBMLDocument, getSBOTerm, getSBOTermID, getURI, getVersion, hasExtension, hasValidAnnotation, hasValidLevelVersionNamespaceCombination, isExtendedByOtherPackages, isIdMandatory, isPackageEnabled, isPackageURIEnabled, isPkgEnabled, isPkgURIEnabled, isSetAnnotation, isSetHistory, isSetId, isSetLevel, isSetLevelAndVersion, isSetMetaId, isSetName, isSetNotes, isSetPackageVErsion, isSetParentSBMLObject, isSetPlugin, isSetSBOTerm, isSetVersion, isValidLevelAndVersionCombination, isValidMetaId, registerChild, removeCVTerm, removeCVTerm, removeDeclaredNamespaceByNamespace, removeDeclaredNamespaceByPrefix, removeTopLevelAnnotationElement, removeTopLevelAnnotationElement, removeTopLevelAnnotationElement, replaceTopLevelAnnotationElement, replaceTopLevelAnnotationElement, setAnnotation, setAnnotation, setAnnotation, setHistory, setId, setLevel, setMetaId, setName, setNamespace, setNotes, setNotes, setPackageVersion, setSBOTerm, setSBOTerm, setThisAsParentSBMLObject, setVersion, toString, unregisterChild, unsetAnnotation, unsetCVTerms, unsetExtension, unsetHistory, unsetId, unsetMetaId, unsetName, unsetNamespace, unsetNotes, unsetPlugin, unsetSBOTerm
addAllChangeListeners, addAllChangeListeners, addTreeNodeChangeListener, addTreeNodeChangeListener, children, clearUserObjects, containsUserObjectKey, filter, filter, filter, fireNodeAddedEvent, getIndex, getListOfTreeNodeChangeListeners, getNumChildren, getRoot, getTreeNodeChangeListenerCount, getUserObject, indexOf, isLeaf, isRoot, isSetParent, isSetUserObjects, putUserObject, removeAllTreeNodeChangeListeners, removeAllTreeNodeChangeListeners, removeFromParent, removeTreeNodeChangeListener, removeTreeNodeChangeListener, removeUserObject, setParent, userObjectKeySet
getType, isCubicBezier, isLineSegment, isSetType, readAttribute, removeEnd, removeStart, writeXMLAttributes
removeTreeNodeChangeListener
addAllChangeListeners, addAllChangeListeners, addTreeNodeChangeListener, addTreeNodeChangeListener, clearUserObjects, containsUserObjectKey, filter, filter, filter, fireNodeAddedEvent, getListOfTreeNodeChangeListeners, getRoot, getTreeNodeChangeListenerCount, getUserObject, isRoot, isSetParent, isSetUserObjects, putUserObject, removeAllTreeNodeChangeListeners, removeAllTreeNodeChangeListeners, removeFromParent, removeTreeNodeChangeListener, removeUserObject, userObjectKeySet
public LineSegment()
public LineSegment(int level, int version)
level
- version
- public LineSegment(LineSegment lineSegment)
lineSegment
- public LineSegment(CurveSegment lineSegment)
lineSegment
- public LineSegment clone()
SBase
SBase
with the same
properties
like this one.clone
in interface SBase
clone
in class AbstractSBase
public Point createEnd()
Point
createEnd
in class CurveSegment
Point
object.public Point createEnd(double x, double y, double z)
Point
based on the
given values.createEnd
in class CurveSegment
x
- y
- z
- Point
object.public Point createStart()
Point
createStart
in class CurveSegment
Point
object.public Point createStart(double x, double y, double z)
Point
based on the
given values.createStart
in class CurveSegment
x
- y
- z
- Point
object.public boolean equals(java.lang.Object object)
SBase
public javax.swing.tree.TreeNode getChildAt(int index)
getChildAt
in interface javax.swing.tree.TreeNode
getChildAt
in class AbstractSBase
public int getChildCount()
getChildCount
in interface javax.swing.tree.TreeNode
getChildCount
in class AbstractSBase
public Point getEnd()
CurveSegment
getEnd
in class CurveSegment
End
Point
of this CurveSegment
.public Point getStart()
CurveSegment
getStart
in class CurveSegment
Start
Point
of this CurveSegment
.public int hashCode()
SBase
SBase
instance.hashCode
in interface SBase
hashCode
in class CurveSegment
SBase
instance.Object.hashCode()
public boolean isSetEnd()
CurveSegment
isSetEnd
in class CurveSegment
true
if the End
Point
is set.public boolean isSetStart()
CurveSegment
isSetStart
in class CurveSegment
true
if the Start
Point
is set.public void setEnd(Point end)
CurveSegment
setEnd
in class CurveSegment
end
- the End
Point
to setpublic void setStart(Point start)
CurveSegment
setStart
in class CurveSegment
start
- the Start
Point
to setpublic void unsetEnd()
LineSegment
unsetEnd
in class CurveSegment
public void unsetStart()
LineSegment
unsetStart
in class CurveSegment