Sophie

Sophie

distrib > Momonga > development > i686 > media > os > by-pkgid > 8094ac79f986f14af880f5f612391693 > files > 163

xml-commons-apis-manual-1.4.01-4m.mo8.noarch.rpm

<?xml version="1.0" encoding="UTF-8"?>
<!--[ Text object description ]-->
<!-- $Date: 2001-06-01 14:15:37 +0300 (Fri, 01 Jun 2001) $ $Revision: 225913 $ -->
<interface name="Text" inherits="CharacterData" id="ID-1312295772"> 
  <descr>
	 <p>The <code>Text</code> interface inherits from <code>CharacterData</code> and represents the textual content (termed
		<xspecref href="&xml-spec;#syntax">character data</xspecref> in XML) of an <code>Element</code> or <code>Attr</code>. If there is no markup inside an element's content, the text is
		contained in a single object implementing the <code>Text</code> interface that is the only child of the element. If there is markup, it
		is parsed into the <termref def="dt-infoitem">information items</termref>
		(elements, comments, etc.) and <code>Text</code> nodes that form the list of children of the element.</p> 
	 <p>When a document is first made available via the DOM, there is only one <code>Text</code> node for each block of text. Users may create adjacent <code>Text</code> nodes that represent the contents of a given element without any
		intervening markup, but should be aware that there is no way to represent the
		separations between these nodes in XML or HTML, so they will not (in general)
		persist between DOM editing sessions. The <code>normalize()</code> method on <code>Node</code> merges any such adjacent <code>Text</code> objects into a single node for each block of text.</p> 
  </descr> 
  <method name="splitText" id="ID-38853C1D"> 
	 <descr>
		<p>Breaks this node into two nodes at the specified <code>offset</code>, keeping both in the tree as <termref
		  def="dt-sibling">siblings</termref>. After being split, this node will contain
		  all the content up to the <code>offset</code> point. A new node of the same type, which contains all the content at
		  and after the <code>offset</code> point, is returned. If the original node had a parent node, the new
		  node is inserted as the next <termref def="dt-sibling">sibling</termref> of the
		  original node. When the <code>offset</code> is equal to the length of this node, the new node has no data.</p>
	 </descr> 
	 <parameters> 
		<param name="offset" type="unsigned long" attr="in">	
		  <descr>
			 <p>The <termref def="dt-16-bit-unit">16-bit unit</termref> offset at
				which to split, starting from <code>0</code>.</p>
		  </descr> 
		</param> 
	 </parameters> 
	 <returns type="Text"> 
		<descr>
		  <p>The new node, of the same type as this node.</p>
		</descr> 
	 </returns> 
	 <raises> 
		<exception name="DOMException"> 
		  <descr>
			 <p>INDEX_SIZE_ERR: Raised if the specified offset is negative or
				greater than the number of 16-bit units in <code>data</code>.</p>	
			 <p>NO_MODIFICATION_ALLOWED_ERR: Raised if this node is readonly.</p>	
		  </descr> 
		</exception> 
	 </raises> 
  </method>
</interface>