summaryrefslogtreecommitdiff
path: root/doc/api/morfologik/fsa/FSAVer5Impl.html
blob: 8c3265e911b9d06a6f866a762a0f7adf6e6b6a5d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!--NewPage-->
<HTML>
<HEAD>
<!-- Generated by javadoc (build 1.6.0_14) on Mon Sep 21 12:09:36 CEST 2009 -->
<TITLE>
FSAVer5Impl
</TITLE>

<META NAME="date" CONTENT="2009-09-21">

<LINK REL ="stylesheet" TYPE="text/css" HREF="../../stylesheet.css" TITLE="Style">

<SCRIPT type="text/javascript">
function windowTitle()
{
    if (location.href.indexOf('is-external=true') == -1) {
        parent.document.title="FSAVer5Impl";
    }
}
</SCRIPT>
<NOSCRIPT>
</NOSCRIPT>

</HEAD>

<BODY BGCOLOR="white" onload="windowTitle();">
<HR>


<!-- ========= START OF TOP NAVBAR ======= -->
<A NAME="navbar_top"><!-- --></A>
<A HREF="#skip-navbar_top" title="Skip navigation links"></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_top_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
  <TR ALIGN="center" VALIGN="top">
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
  </TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>

<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
&nbsp;<A HREF="../../morfologik/fsa/FSATraversalHelper.html" title="class in morfologik.fsa"><B>PREV CLASS</B></A>&nbsp;
&nbsp;NEXT CLASS</FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
  <A HREF="../../index.html?morfologik/fsa/FSAVer5Impl.html" target="_top"><B>FRAMES</B></A>  &nbsp;
&nbsp;<A HREF="FSAVer5Impl.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;
&nbsp;<SCRIPT type="text/javascript">
  <!--
  if(window==top) {
    document.writeln('<A HREF="../../allclasses-noframe.html"><B>All Classes</B></A>');
  }
  //-->
</SCRIPT>
<NOSCRIPT>
  <A HREF="../../allclasses-noframe.html"><B>All Classes</B></A>
</NOSCRIPT>


</FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
  SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;<A HREF="#field_summary">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL:&nbsp;<A HREF="#field_detail">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<A NAME="skip-navbar_top"></A>
<!-- ========= END OF TOP NAVBAR ========= -->

<HR>
<!-- ======== START OF CLASS DATA ======== -->
<H2>
<FONT SIZE="-1">
morfologik.fsa</FONT>
<BR>
Class FSAVer5Impl</H2>
<PRE>
java.lang.Object
  <IMG SRC="../../resources/inherit.gif" ALT="extended by "><A HREF="../../morfologik/fsa/FSA.html" title="class in morfologik.fsa">morfologik.fsa.FSA</A>
      <IMG SRC="../../resources/inherit.gif" ALT="extended by "><B>morfologik.fsa.FSAVer5Impl</B>
</PRE>
<DL>
<DT><B>All Implemented Interfaces:</B> <DD>java.lang.Iterable&lt;java.nio.ByteBuffer&gt;</DD>
</DL>
<HR>
<DL>
<DT><PRE>public final class <B>FSAVer5Impl</B><DT>extends <A HREF="../../morfologik/fsa/FSA.html" title="class in morfologik.fsa">FSA</A></DL>
</PRE>

<P>
FSA (Finite State Automaton) dictionary traversal implementation for version
 5 of the FSA automaton.
 
 <p>
 Version 5 indicates the dictionary was built with these flags:
 <A HREF="../../morfologik/fsa/FSAFlags.html#FLEXIBLE"><CODE>FSAFlags.FLEXIBLE</CODE></A>, <A HREF="../../morfologik/fsa/FSAFlags.html#STOPBIT"><CODE>FSAFlags.STOPBIT</CODE></A> and
 <A HREF="../../morfologik/fsa/FSAFlags.html#NEXTBIT"><CODE>FSAFlags.NEXTBIT</CODE></A>. The internal representation of the FSA must
 therefore follow this description (please note this format describes only a
 single transition (arc), not the entire dictionary file).
 
 <pre>
 Byte
       +-+-+-+-+-+-+-+-+\
     0 | | | | | | | | | +------ label
       +-+-+-+-+-+-+-+-+/
 
                  +------------- node pointed to is next
                  | +----------- the last arc of the node
                  | | +--------- the arc is final
                  | | |
             +-----------+
             |    | | |  |
         ___+___  | | |  |
        /       \ | | |  |
       MSB           LSB |
        7 6 5 4 3 2 1 0  |
       +-+-+-+-+-+-+-+-+ |
     1 | | | | | | | | | \ \
       +-+-+-+-+-+-+-+-+  \ \  LSB
       +-+-+-+-+-+-+-+-+     +
     2 | | | | | | | | |     |
       +-+-+-+-+-+-+-+-+     |
     3 | | | | | | | | |     +----- target node address (in bytes)
       +-+-+-+-+-+-+-+-+     |      (not present except for the byte
       : : : : : : : : :     |       with flags if the node pointed to
       +-+-+-+-+-+-+-+-+     +       is next)
   gtl | | | | | | | | |    /  MSB
       +-+-+-+-+-+-+-+-+   /
 gtl+1                           (gtl = gotoLength)
 </pre>
<P>

<P>
<HR>

<P>
<!-- =========== FIELD SUMMARY =========== -->

<A NAME="field_summary"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
<B>Field Summary</B></FONT></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>protected &nbsp;byte[]</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../morfologik/fsa/FSAVer5Impl.html#arcs">arcs</A></B></CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;An array of bytes with the internal representation of the automaton.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>protected &nbsp;int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../morfologik/fsa/FSAVer5Impl.html#arcSize">arcSize</A></B></CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Size of a single arc (in bytes).</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>protected static&nbsp;int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../morfologik/fsa/FSAVer5Impl.html#gotoOffset">gotoOffset</A></B></CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;An offset in the arc structure, where the address field begins.</TD>
</TR>
</TABLE>
&nbsp;<A NAME="fields_inherited_from_class_morfologik.fsa.FSA"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
<TH ALIGN="left"><B>Fields inherited from class morfologik.fsa.<A HREF="../../morfologik/fsa/FSA.html" title="class in morfologik.fsa">FSA</A></B></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><A HREF="../../morfologik/fsa/FSA.html#filler">filler</A>, <A HREF="../../morfologik/fsa/FSA.html#gotoLength">gotoLength</A>, <A HREF="../../morfologik/fsa/FSA.html#version">version</A>, <A HREF="../../morfologik/fsa/FSA.html#VERSION_5">VERSION_5</A></CODE></TD>
</TR>
</TABLE>
&nbsp;
<!-- ======== CONSTRUCTOR SUMMARY ======== -->

<A NAME="constructor_summary"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
<B>Constructor Summary</B></FONT></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><B><A HREF="../../morfologik/fsa/FSAVer5Impl.html#FSAVer5Impl(java.io.InputStream, java.lang.String)">FSAVer5Impl</A></B>(java.io.InputStream&nbsp;fsaStream,
            java.lang.String&nbsp;dictionaryEncoding)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Creates a new automaton reading it from a file in FSA format, version 5.</TD>
</TR>
</TABLE>
&nbsp;
<!-- ========== METHOD SUMMARY =========== -->

<A NAME="method_summary"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
<B>Method Summary</B></FONT></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../morfologik/fsa/FSAVer5Impl.html#getArc(int, byte)">getArc</A></B>(int&nbsp;node,
       byte&nbsp;label)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the identifier of an arc leaving <code>node</code> and labeled
 with <code>label</code>.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;byte</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../morfologik/fsa/FSAVer5Impl.html#getArcLabel(int)">getArcLabel</A></B>(int&nbsp;arc)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Return the label associated with a given <code>arc</code>.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../morfologik/fsa/FSAVer5Impl.html#getEndNode(int)">getEndNode</A></B>(int&nbsp;arc)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Return the end node pointed to by a given <code>arc</code>.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../morfologik/fsa/FSAVer5Impl.html#getFirstArc(int)">getFirstArc</A></B>(int&nbsp;node)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the identifier of the first arc leaving <code>node</code> or 0 if
 the node has no outgoing arcs.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../morfologik/fsa/FSAVer5Impl.html#getNextArc(int, int)">getNextArc</A></B>(int&nbsp;node,
           int&nbsp;arc)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the identifier of the next arc after <code>arc</code> and leaving
 <code>node</code>.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../morfologik/fsa/FSAVer5Impl.html#getNumberOfArcs()">getNumberOfArcs</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the number of arcs in this automaton.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../morfologik/fsa/FSAVer5Impl.html#getNumberOfNodes()">getNumberOfNodes</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the number of nodes in this automaton.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;int</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../morfologik/fsa/FSAVer5Impl.html#getRootNode()">getRootNode</A></B>()</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the start node of this automaton.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;boolean</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../morfologik/fsa/FSAVer5Impl.html#isArcFinal(int)">isArcFinal</A></B>(int&nbsp;arc)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns <code>true</code> if the destination node at the end of this
 <code>arc</code> corresponds to an input sequence created when building
 this automaton.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>&nbsp;boolean</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../morfologik/fsa/FSAVer5Impl.html#isArcTerminal(int)">isArcTerminal</A></B>(int&nbsp;arc)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns <code>true</code> if this <code>arc</code> does not have a
 terminating node.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>protected &nbsp;void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../morfologik/fsa/FSAVer5Impl.html#readHeader(java.io.DataInput, long)">readHeader</A></B>(java.io.DataInput&nbsp;in,
           long&nbsp;fileSize)</CODE>

<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Reads a FSA header from a stream.</TD>
</TR>
</TABLE>
&nbsp;<A NAME="methods_inherited_from_class_morfologik.fsa.FSA"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
<TH ALIGN="left"><B>Methods inherited from class morfologik.fsa.<A HREF="../../morfologik/fsa/FSA.html" title="class in morfologik.fsa">FSA</A></B></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><A HREF="../../morfologik/fsa/FSA.html#getAnnotationSeparator()">getAnnotationSeparator</A>, <A HREF="../../morfologik/fsa/FSA.html#getFillerCharacter()">getFillerCharacter</A>, <A HREF="../../morfologik/fsa/FSA.html#getFlags()">getFlags</A>, <A HREF="../../morfologik/fsa/FSA.html#getInstance(java.io.File, java.lang.String)">getInstance</A>, <A HREF="../../morfologik/fsa/FSA.html#getInstance(java.io.InputStream, java.lang.String)">getInstance</A>, <A HREF="../../morfologik/fsa/FSA.html#getTraversalHelper()">getTraversalHelper</A>, <A HREF="../../morfologik/fsa/FSA.html#getVersion()">getVersion</A>, <A HREF="../../morfologik/fsa/FSA.html#iterator()">iterator</A>, <A HREF="../../morfologik/fsa/FSA.html#readFully(java.io.InputStream)">readFully</A></CODE></TD>
</TR>
</TABLE>
&nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
<TH ALIGN="left"><B>Methods inherited from class java.lang.Object</B></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE>clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait</CODE></TD>
</TR>
</TABLE>
&nbsp;
<P>

<!-- ============ FIELD DETAIL =========== -->

<A NAME="field_detail"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
<B>Field Detail</B></FONT></TH>
</TR>
</TABLE>

<A NAME="arcSize"><!-- --></A><H3>
arcSize</H3>
<PRE>
protected int <B>arcSize</B></PRE>
<DL>
<DD>Size of a single arc (in bytes).
<P>
<DL>
</DL>
</DL>
<HR>

<A NAME="gotoOffset"><!-- --></A><H3>
gotoOffset</H3>
<PRE>
protected static final int <B>gotoOffset</B></PRE>
<DL>
<DD>An offset in the arc structure, where the address field begins. For this
 version of the automaton, this is a constant value.
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../constant-values.html#morfologik.fsa.FSAVer5Impl.gotoOffset">Constant Field Values</A></DL>
</DL>
<HR>

<A NAME="arcs"><!-- --></A><H3>
arcs</H3>
<PRE>
protected byte[] <B>arcs</B></PRE>
<DL>
<DD>An array of bytes with the internal representation of the automaton.
 Please see the documentation of this class for more information on how
 this structure is organized.
<P>
<DL>
</DL>
</DL>

<!-- ========= CONSTRUCTOR DETAIL ======== -->

<A NAME="constructor_detail"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
<B>Constructor Detail</B></FONT></TH>
</TR>
</TABLE>

<A NAME="FSAVer5Impl(java.io.InputStream, java.lang.String)"><!-- --></A><H3>
FSAVer5Impl</H3>
<PRE>
public <B>FSAVer5Impl</B>(java.io.InputStream&nbsp;fsaStream,
                   java.lang.String&nbsp;dictionaryEncoding)
            throws java.io.IOException</PRE>
<DL>
<DD>Creates a new automaton reading it from a file in FSA format, version 5.
<P>
<DL>

<DT><B>Throws:</B>
<DD><CODE>java.io.IOException</CODE></DL>
</DL>

<!-- ============ METHOD DETAIL ========== -->

<A NAME="method_detail"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
<B>Method Detail</B></FONT></TH>
</TR>
</TABLE>

<A NAME="getNumberOfArcs()"><!-- --></A><H3>
getNumberOfArcs</H3>
<PRE>
public int <B>getNumberOfArcs</B>()</PRE>
<DL>
<DD>Returns the number of arcs in this automaton. This method performs a full
 scan of all arcs in this automaton.
<P>
<DD><DL>
<DT><B>Specified by:</B><DD><CODE><A HREF="../../morfologik/fsa/FSA.html#getNumberOfArcs()">getNumberOfArcs</A></CODE> in class <CODE><A HREF="../../morfologik/fsa/FSA.html" title="class in morfologik.fsa">FSA</A></CODE></DL>
</DD>
<DD><DL>
</DL>
</DD>
</DL>
<HR>

<A NAME="getNumberOfNodes()"><!-- --></A><H3>
getNumberOfNodes</H3>
<PRE>
public int <B>getNumberOfNodes</B>()</PRE>
<DL>
<DD>Returns the number of nodes in this automaton. This method performs a
 full scan of all arcs in this automaton.
<P>
<DD><DL>
<DT><B>Specified by:</B><DD><CODE><A HREF="../../morfologik/fsa/FSA.html#getNumberOfNodes()">getNumberOfNodes</A></CODE> in class <CODE><A HREF="../../morfologik/fsa/FSA.html" title="class in morfologik.fsa">FSA</A></CODE></DL>
</DD>
<DD><DL>
</DL>
</DD>
</DL>
<HR>

<A NAME="getRootNode()"><!-- --></A><H3>
getRootNode</H3>
<PRE>
public int <B>getRootNode</B>()</PRE>
<DL>
<DD>Returns the start node of this automaton. May return <code>0</code> if
 the start node is also an end node.
<P>
<DD><DL>
<DT><B>Specified by:</B><DD><CODE><A HREF="../../morfologik/fsa/FSA.html#getRootNode()">getRootNode</A></CODE> in class <CODE><A HREF="../../morfologik/fsa/FSA.html" title="class in morfologik.fsa">FSA</A></CODE></DL>
</DD>
<DD><DL>
<DT><B>See Also:</B><DD><A HREF="../../morfologik/fsa/FSA.html#getTraversalHelper()"><CODE>FSA.getTraversalHelper()</CODE></A></DL>
</DD>
</DL>
<HR>

<A NAME="readHeader(java.io.DataInput, long)"><!-- --></A><H3>
readHeader</H3>
<PRE>
protected void <B>readHeader</B>(java.io.DataInput&nbsp;in,
                          long&nbsp;fileSize)
                   throws java.io.IOException</PRE>
<DL>
<DD>Reads a FSA header from a stream.
<P>
<DD><DL>
<DT><B>Overrides:</B><DD><CODE><A HREF="../../morfologik/fsa/FSA.html#readHeader(java.io.DataInput, long)">readHeader</A></CODE> in class <CODE><A HREF="../../morfologik/fsa/FSA.html" title="class in morfologik.fsa">FSA</A></CODE></DL>
</DD>
<DD><DL>

<DT><B>Throws:</B>
<DD><CODE>java.io.IOException</CODE> - If the stream is not a dictionary, or if the version is not
             supported.</DL>
</DD>
</DL>
<HR>

<A NAME="getFirstArc(int)"><!-- --></A><H3>
getFirstArc</H3>
<PRE>
public final int <B>getFirstArc</B>(int&nbsp;node)</PRE>
<DL>
<DD><B>Description copied from class: <CODE><A HREF="../../morfologik/fsa/FSA.html#getFirstArc(int)">FSA</A></CODE></B></DD>
<DD>Returns the identifier of the first arc leaving <code>node</code> or 0 if
 the node has no outgoing arcs.
<P>
<DD><DL>
<DT><B>Specified by:</B><DD><CODE><A HREF="../../morfologik/fsa/FSA.html#getFirstArc(int)">getFirstArc</A></CODE> in class <CODE><A HREF="../../morfologik/fsa/FSA.html" title="class in morfologik.fsa">FSA</A></CODE></DL>
</DD>
<DD><DL>
<DT><B>See Also:</B><DD><A HREF="../../morfologik/fsa/FSA.html#getTraversalHelper()"><CODE>FSA.getTraversalHelper()</CODE></A></DL>
</DD>
</DL>
<HR>

<A NAME="getNextArc(int, int)"><!-- --></A><H3>
getNextArc</H3>
<PRE>
public final int <B>getNextArc</B>(int&nbsp;node,
                            int&nbsp;arc)</PRE>
<DL>
<DD><B>Description copied from class: <CODE><A HREF="../../morfologik/fsa/FSA.html#getNextArc(int, int)">FSA</A></CODE></B></DD>
<DD>Returns the identifier of the next arc after <code>arc</code> and leaving
 <code>node</code>. Zero is returned if no more arcs are available for the
 node.
<P>
<DD><DL>
<DT><B>Specified by:</B><DD><CODE><A HREF="../../morfologik/fsa/FSA.html#getNextArc(int, int)">getNextArc</A></CODE> in class <CODE><A HREF="../../morfologik/fsa/FSA.html" title="class in morfologik.fsa">FSA</A></CODE></DL>
</DD>
<DD><DL>
<DT><B>See Also:</B><DD><A HREF="../../morfologik/fsa/FSA.html#getTraversalHelper()"><CODE>FSA.getTraversalHelper()</CODE></A></DL>
</DD>
</DL>
<HR>

<A NAME="getArc(int, byte)"><!-- --></A><H3>
getArc</H3>
<PRE>
public int <B>getArc</B>(int&nbsp;node,
                  byte&nbsp;label)</PRE>
<DL>
<DD><B>Description copied from class: <CODE><A HREF="../../morfologik/fsa/FSA.html#getArc(int, byte)">FSA</A></CODE></B></DD>
<DD>Returns the identifier of an arc leaving <code>node</code> and labeled
 with <code>label</code>. An identifier equal to 0 means the node has no
 outgoing arc labeled <code>label</code>.
<P>
<DD><DL>
<DT><B>Specified by:</B><DD><CODE><A HREF="../../morfologik/fsa/FSA.html#getArc(int, byte)">getArc</A></CODE> in class <CODE><A HREF="../../morfologik/fsa/FSA.html" title="class in morfologik.fsa">FSA</A></CODE></DL>
</DD>
<DD><DL>
<DT><B>See Also:</B><DD><A HREF="../../morfologik/fsa/FSA.html#getTraversalHelper()"><CODE>FSA.getTraversalHelper()</CODE></A></DL>
</DD>
</DL>
<HR>

<A NAME="getEndNode(int)"><!-- --></A><H3>
getEndNode</H3>
<PRE>
public int <B>getEndNode</B>(int&nbsp;arc)</PRE>
<DL>
<DD><B>Description copied from class: <CODE><A HREF="../../morfologik/fsa/FSA.html#getEndNode(int)">FSA</A></CODE></B></DD>
<DD>Return the end node pointed to by a given <code>arc</code>. Terminal arcs
 (those that point to a terminal state) have no end node representation
 and throw a runtime exception.
<P>
<DD><DL>
<DT><B>Specified by:</B><DD><CODE><A HREF="../../morfologik/fsa/FSA.html#getEndNode(int)">getEndNode</A></CODE> in class <CODE><A HREF="../../morfologik/fsa/FSA.html" title="class in morfologik.fsa">FSA</A></CODE></DL>
</DD>
<DD><DL>
<DT><B>See Also:</B><DD><A HREF="../../morfologik/fsa/FSA.html#getTraversalHelper()"><CODE>FSA.getTraversalHelper()</CODE></A></DL>
</DD>
</DL>
<HR>

<A NAME="getArcLabel(int)"><!-- --></A><H3>
getArcLabel</H3>
<PRE>
public byte <B>getArcLabel</B>(int&nbsp;arc)</PRE>
<DL>
<DD><B>Description copied from class: <CODE><A HREF="../../morfologik/fsa/FSA.html#getArcLabel(int)">FSA</A></CODE></B></DD>
<DD>Return the label associated with a given <code>arc</code>.
<P>
<DD><DL>
<DT><B>Specified by:</B><DD><CODE><A HREF="../../morfologik/fsa/FSA.html#getArcLabel(int)">getArcLabel</A></CODE> in class <CODE><A HREF="../../morfologik/fsa/FSA.html" title="class in morfologik.fsa">FSA</A></CODE></DL>
</DD>
<DD><DL>
</DL>
</DD>
</DL>
<HR>

<A NAME="isArcFinal(int)"><!-- --></A><H3>
isArcFinal</H3>
<PRE>
public boolean <B>isArcFinal</B>(int&nbsp;arc)</PRE>
<DL>
<DD><B>Description copied from class: <CODE><A HREF="../../morfologik/fsa/FSA.html#isArcFinal(int)">FSA</A></CODE></B></DD>
<DD>Returns <code>true</code> if the destination node at the end of this
 <code>arc</code> corresponds to an input sequence created when building
 this automaton.
<P>
<DD><DL>
<DT><B>Specified by:</B><DD><CODE><A HREF="../../morfologik/fsa/FSA.html#isArcFinal(int)">isArcFinal</A></CODE> in class <CODE><A HREF="../../morfologik/fsa/FSA.html" title="class in morfologik.fsa">FSA</A></CODE></DL>
</DD>
<DD><DL>
</DL>
</DD>
</DL>
<HR>

<A NAME="isArcTerminal(int)"><!-- --></A><H3>
isArcTerminal</H3>
<PRE>
public boolean <B>isArcTerminal</B>(int&nbsp;arc)</PRE>
<DL>
<DD><B>Description copied from class: <CODE><A HREF="../../morfologik/fsa/FSA.html#isArcTerminal(int)">FSA</A></CODE></B></DD>
<DD>Returns <code>true</code> if this <code>arc</code> does not have a
 terminating node.
<P>
<DD><DL>
<DT><B>Specified by:</B><DD><CODE><A HREF="../../morfologik/fsa/FSA.html#isArcTerminal(int)">isArcTerminal</A></CODE> in class <CODE><A HREF="../../morfologik/fsa/FSA.html" title="class in morfologik.fsa">FSA</A></CODE></DL>
</DD>
<DD><DL>
</DL>
</DD>
</DL>
<!-- ========= END OF CLASS DATA ========= -->
<HR>


<!-- ======= START OF BOTTOM NAVBAR ====== -->
<A NAME="navbar_bottom"><!-- --></A>
<A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_bottom_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
  <TR ALIGN="center" VALIGN="top">
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>
  <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>
  </TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>

<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
&nbsp;<A HREF="../../morfologik/fsa/FSATraversalHelper.html" title="class in morfologik.fsa"><B>PREV CLASS</B></A>&nbsp;
&nbsp;NEXT CLASS</FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
  <A HREF="../../index.html?morfologik/fsa/FSAVer5Impl.html" target="_top"><B>FRAMES</B></A>  &nbsp;
&nbsp;<A HREF="FSAVer5Impl.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;
&nbsp;<SCRIPT type="text/javascript">
  <!--
  if(window==top) {
    document.writeln('<A HREF="../../allclasses-noframe.html"><B>All Classes</B></A>');
  }
  //-->
</SCRIPT>
<NOSCRIPT>
  <A HREF="../../allclasses-noframe.html"><B>All Classes</B></A>
</NOSCRIPT>


</FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
  SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;<A HREF="#field_summary">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL:&nbsp;<A HREF="#field_detail">FIELD</A>&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<A NAME="skip-navbar_bottom"></A>
<!-- ======== END OF BOTTOM NAVBAR ======= -->

<HR>

</BODY>
</HTML>