super (name);
}
public void testNewPutSizeFreeze ()
{
Alphabet dict = new Alphabet ();
FeatureSequence fs = new FeatureSequence (dict, 10);
fs.add (dict.lookupIndex ("apple"));
fs.add (dict.lookupIndex ("bear"));
fs.add (dict.lookupIndex ("car"));
fs.add (dict.lookupIndex ("door"));
assertTrue (fs.size() == 4);
double[] weights = new double[4];
fs.addFeatureWeightsTo (weights);
assertTrue (weights[1] == 1.0);
fs.add (dict.lookupIndex ("bear"));
int[] feats = fs.toFeatureIndexSequence();
assertTrue (feats[0] == 0);
assertTrue (feats[1] == 1);
assertTrue (feats[2] == 2);
assertTrue (feats[3] == 3);