xref: /plugin/aichat/vendor/vanderlee/php-sentence/doc/class-Sentence.html (revision 8817535b0c67f8b10e9b8c05dcdf58fc17827423)
1*8817535bSAndreas Gohr<!DOCTYPE html>
2*8817535bSAndreas Gohr<html>
3*8817535bSAndreas Gohr<head>
4*8817535bSAndreas Gohr	<meta charset="utf-8">
5*8817535bSAndreas Gohr
6*8817535bSAndreas Gohr	<title>Class Sentence | phpSentence</title>
7*8817535bSAndreas Gohr
8*8817535bSAndreas Gohr	<link rel="stylesheet" href="resources/style.css?e99947befd7bf673c6b43ff75e9e0f170c88a60e">
9*8817535bSAndreas Gohr
10*8817535bSAndreas Gohr</head>
11*8817535bSAndreas Gohr
12*8817535bSAndreas Gohr<body>
13*8817535bSAndreas Gohr<div id="left">
14*8817535bSAndreas Gohr	<div id="menu">
15*8817535bSAndreas Gohr		<a href="index.html" title="Overview"><span>Overview</span></a>
16*8817535bSAndreas Gohr
17*8817535bSAndreas Gohr
18*8817535bSAndreas Gohr		<div id="groups">
19*8817535bSAndreas Gohr		</div>
20*8817535bSAndreas Gohr
21*8817535bSAndreas Gohr
22*8817535bSAndreas Gohr
23*8817535bSAndreas Gohr		<div id="elements">
24*8817535bSAndreas Gohr			<h3>Classes</h3>
25*8817535bSAndreas Gohr			<ul>
26*8817535bSAndreas Gohr				<li class="active"><a href="class-Sentence.html">Sentence</a></li>
27*8817535bSAndreas Gohr				<li><a href="class-SentenceTest.html">SentenceTest</a></li>
28*8817535bSAndreas Gohr			</ul>
29*8817535bSAndreas Gohr
30*8817535bSAndreas Gohr
31*8817535bSAndreas Gohr
32*8817535bSAndreas Gohr
33*8817535bSAndreas Gohr
34*8817535bSAndreas Gohr			<h3>Functions</h3>
35*8817535bSAndreas Gohr			<ul>
36*8817535bSAndreas Gohr				<li><a href="function-Sentence_autoloader.html">Sentence_autoloader</a></li>
37*8817535bSAndreas Gohr			</ul>
38*8817535bSAndreas Gohr		</div>
39*8817535bSAndreas Gohr	</div>
40*8817535bSAndreas Gohr</div>
41*8817535bSAndreas Gohr
42*8817535bSAndreas Gohr<div id="splitter"></div>
43*8817535bSAndreas Gohr
44*8817535bSAndreas Gohr<div id="right">
45*8817535bSAndreas Gohr<div id="rightInner">
46*8817535bSAndreas Gohr	<form id="search">
47*8817535bSAndreas Gohr		<input type="hidden" name="cx" value="">
48*8817535bSAndreas Gohr		<input type="hidden" name="ie" value="UTF-8">
49*8817535bSAndreas Gohr		<input type="text" name="q" class="text" placeholder="Search">
50*8817535bSAndreas Gohr	</form>
51*8817535bSAndreas Gohr
52*8817535bSAndreas Gohr	<div id="navigation">
53*8817535bSAndreas Gohr		<ul>
54*8817535bSAndreas Gohr			<li>
55*8817535bSAndreas Gohr				<a href="index.html" title="Overview"><span>Overview</span></a>
56*8817535bSAndreas Gohr			</li>
57*8817535bSAndreas Gohr			<li class="active">
58*8817535bSAndreas Gohr<span>Class</span>			</li>
59*8817535bSAndreas Gohr		</ul>
60*8817535bSAndreas Gohr		<ul>
61*8817535bSAndreas Gohr		</ul>
62*8817535bSAndreas Gohr		<ul>
63*8817535bSAndreas Gohr		</ul>
64*8817535bSAndreas Gohr	</div>
65*8817535bSAndreas Gohr
66*8817535bSAndreas Gohr<div id="content" class="class">
67*8817535bSAndreas Gohr	<h1>Class Sentence</h1>
68*8817535bSAndreas Gohr
69*8817535bSAndreas Gohr
70*8817535bSAndreas Gohr	<div class="description">
71*8817535bSAndreas Gohr	<p>Segments sentences.
72*8817535bSAndreas GohrClipping may not be perfect.
73*8817535bSAndreas GohrSentence count should be VERY close to the truth.</p>
74*8817535bSAndreas Gohr
75*8817535bSAndreas Gohr<p>Multibyte safe (atleast for UTF-8), but rules based on germanic
76*8817535bSAndreas Gohrlanguage stucture (English, Dutch, German). Should work for most
77*8817535bSAndreas Gohrlatin-alphabet languages.</p>
78*8817535bSAndreas Gohr	</div>
79*8817535bSAndreas Gohr
80*8817535bSAndreas Gohr
81*8817535bSAndreas Gohr
82*8817535bSAndreas Gohr
83*8817535bSAndreas Gohr
84*8817535bSAndreas Gohr
85*8817535bSAndreas Gohr
86*8817535bSAndreas Gohr
87*8817535bSAndreas Gohr
88*8817535bSAndreas Gohr	<div class="info">
89*8817535bSAndreas Gohr
90*8817535bSAndreas Gohr
91*8817535bSAndreas Gohr
92*8817535bSAndreas Gohr
93*8817535bSAndreas Gohr
94*8817535bSAndreas Gohr			<b>Located at</b> <a href="source-class-Sentence.html#3-328" title="Go to source code">classes/Sentence.php</a>
95*8817535bSAndreas Gohr		<br>
96*8817535bSAndreas Gohr	</div>
97*8817535bSAndreas Gohr
98*8817535bSAndreas Gohr
99*8817535bSAndreas Gohr
100*8817535bSAndreas Gohr	<table class="summary methods" id="methods">
101*8817535bSAndreas Gohr	<caption>Methods summary</caption>
102*8817535bSAndreas Gohr	<tr data-order="split" id="_split">
103*8817535bSAndreas Gohr
104*8817535bSAndreas Gohr		<td class="attributes"><code>
105*8817535bSAndreas Gohr			 public
106*8817535bSAndreas Gohr
107*8817535bSAndreas Gohr			array
108*8817535bSAndreas Gohr
109*8817535bSAndreas Gohr			</code>
110*8817535bSAndreas Gohr		</td>
111*8817535bSAndreas Gohr
112*8817535bSAndreas Gohr		<td class="name"><div>
113*8817535bSAndreas Gohr		<a class="anchor" href="#_split">#</a>
114*8817535bSAndreas Gohr		<code><a href="source-class-Sentence.html#289-318" title="Go to source code">split</a>( <span>string <var>$text</var></span>, <span>integer <var>$flags</var> = <span class="php-num">0</span></span> )</code>
115*8817535bSAndreas Gohr
116*8817535bSAndreas Gohr		<div class="description short">
117*8817535bSAndreas Gohr			<p>Return the sentences sentences detected in the provided text.
118*8817535bSAndreas GohrSet the Sentence::SPLIT_TRIM flag to trim whitespace.</p>
119*8817535bSAndreas Gohr		</div>
120*8817535bSAndreas Gohr
121*8817535bSAndreas Gohr		<div class="description detailed hidden">
122*8817535bSAndreas Gohr			<p>Return the sentences sentences detected in the provided text.
123*8817535bSAndreas GohrSet the Sentence::SPLIT_TRIM flag to trim whitespace.</p>
124*8817535bSAndreas Gohr
125*8817535bSAndreas Gohr
126*8817535bSAndreas Gohr				<h4>Parameters</h4>
127*8817535bSAndreas Gohr				<div class="list"><dl>
128*8817535bSAndreas Gohr					<dt><var>$text</var></dt>
129*8817535bSAndreas Gohr					<dd></dd>
130*8817535bSAndreas Gohr					<dt><var>$flags</var></dt>
131*8817535bSAndreas Gohr					<dd></dd>
132*8817535bSAndreas Gohr				</dl></div>
133*8817535bSAndreas Gohr
134*8817535bSAndreas Gohr				<h4>Returns</h4>
135*8817535bSAndreas Gohr				<div class="list">
136*8817535bSAndreas Gohr					array
137*8817535bSAndreas Gohr				</div>
138*8817535bSAndreas Gohr
139*8817535bSAndreas Gohr
140*8817535bSAndreas Gohr
141*8817535bSAndreas Gohr
142*8817535bSAndreas Gohr		</div>
143*8817535bSAndreas Gohr		</div></td>
144*8817535bSAndreas Gohr	</tr>
145*8817535bSAndreas Gohr	<tr data-order="count" id="_count">
146*8817535bSAndreas Gohr
147*8817535bSAndreas Gohr		<td class="attributes"><code>
148*8817535bSAndreas Gohr			 public
149*8817535bSAndreas Gohr
150*8817535bSAndreas Gohr			integer
151*8817535bSAndreas Gohr
152*8817535bSAndreas Gohr			</code>
153*8817535bSAndreas Gohr		</td>
154*8817535bSAndreas Gohr
155*8817535bSAndreas Gohr		<td class="name"><div>
156*8817535bSAndreas Gohr		<a class="anchor" href="#_count">#</a>
157*8817535bSAndreas Gohr		<code><a href="source-class-Sentence.html#320-327" title="Go to source code">count</a>( <span>string <var>$text</var></span> )</code>
158*8817535bSAndreas Gohr
159*8817535bSAndreas Gohr		<div class="description short">
160*8817535bSAndreas Gohr			<p>Return the number of sentences detected in the provided text.</p>
161*8817535bSAndreas Gohr		</div>
162*8817535bSAndreas Gohr
163*8817535bSAndreas Gohr		<div class="description detailed hidden">
164*8817535bSAndreas Gohr			<p>Return the number of sentences detected in the provided text.</p>
165*8817535bSAndreas Gohr
166*8817535bSAndreas Gohr
167*8817535bSAndreas Gohr				<h4>Parameters</h4>
168*8817535bSAndreas Gohr				<div class="list"><dl>
169*8817535bSAndreas Gohr					<dt><var>$text</var></dt>
170*8817535bSAndreas Gohr					<dd></dd>
171*8817535bSAndreas Gohr				</dl></div>
172*8817535bSAndreas Gohr
173*8817535bSAndreas Gohr				<h4>Returns</h4>
174*8817535bSAndreas Gohr				<div class="list">
175*8817535bSAndreas Gohr					integer
176*8817535bSAndreas Gohr				</div>
177*8817535bSAndreas Gohr
178*8817535bSAndreas Gohr
179*8817535bSAndreas Gohr
180*8817535bSAndreas Gohr
181*8817535bSAndreas Gohr		</div>
182*8817535bSAndreas Gohr		</div></td>
183*8817535bSAndreas Gohr	</tr>
184*8817535bSAndreas Gohr	</table>
185*8817535bSAndreas Gohr
186*8817535bSAndreas Gohr
187*8817535bSAndreas Gohr
188*8817535bSAndreas Gohr
189*8817535bSAndreas Gohr
190*8817535bSAndreas Gohr
191*8817535bSAndreas Gohr
192*8817535bSAndreas Gohr
193*8817535bSAndreas Gohr	<table class="summary constants" id="constants">
194*8817535bSAndreas Gohr	<caption>Constants summary</caption>
195*8817535bSAndreas Gohr	<tr data-order="SPLIT_TRIM" id="SPLIT_TRIM">
196*8817535bSAndreas Gohr
197*8817535bSAndreas Gohr		<td class="attributes"><code>integer</code></td>
198*8817535bSAndreas Gohr		<td class="name">
199*8817535bSAndreas Gohr			<code>
200*8817535bSAndreas Gohr				<a href="source-class-Sentence.html#13-16" title="Go to source code"><b>SPLIT_TRIM</b></a>
201*8817535bSAndreas Gohr			</code>
202*8817535bSAndreas Gohr
203*8817535bSAndreas Gohr			<div class="description short">
204*8817535bSAndreas Gohr				<p>Specify this flag with the split method to trim whitespace.</p>
205*8817535bSAndreas Gohr			</div>
206*8817535bSAndreas Gohr
207*8817535bSAndreas Gohr			<div class="description detailed hidden">
208*8817535bSAndreas Gohr				<p>Specify this flag with the split method to trim whitespace.</p>
209*8817535bSAndreas Gohr
210*8817535bSAndreas Gohr			</div>
211*8817535bSAndreas Gohr		</td>
212*8817535bSAndreas Gohr		<td class="value">
213*8817535bSAndreas Gohr			<div>
214*8817535bSAndreas Gohr				<a href="#SPLIT_TRIM" class="anchor">#</a>
215*8817535bSAndreas Gohr				<code><span class="php-num">0x1</span></code>
216*8817535bSAndreas Gohr			</div>
217*8817535bSAndreas Gohr		</td>
218*8817535bSAndreas Gohr	</tr>
219*8817535bSAndreas Gohr	</table>
220*8817535bSAndreas Gohr
221*8817535bSAndreas Gohr
222*8817535bSAndreas Gohr
223*8817535bSAndreas Gohr
224*8817535bSAndreas Gohr
225*8817535bSAndreas Gohr
226*8817535bSAndreas Gohr
227*8817535bSAndreas Gohr
228*8817535bSAndreas Gohr
229*8817535bSAndreas Gohr
230*8817535bSAndreas Gohr</div>
231*8817535bSAndreas Gohr
232*8817535bSAndreas Gohr	<div id="footer">
233*8817535bSAndreas Gohr		phpSentence API documentation generated by <a href="http://apigen.org">ApiGen</a>
234*8817535bSAndreas Gohr	</div>
235*8817535bSAndreas Gohr</div>
236*8817535bSAndreas Gohr</div>
237*8817535bSAndreas Gohr<script src="resources/combined.js"></script>
238*8817535bSAndreas Gohr<script src="elementlist.js"></script>
239*8817535bSAndreas Gohr</body>
240*8817535bSAndreas Gohr</html>
241