/** @generated * @param jcas JCas to which this Feature Structure belongs * @param begin offset to the begin spot in the SofA * @param end offset to the end spot in the SofA */ public Section(JCas jcas, int begin, int end) { super(jcas); setBegin(begin); setEnd(end); readObject(); }
static boolean extractReferencesNaively(JCas jCas) { // match potential sections List<Section> sections = newArrayList(); Matcher m = REFERENCES.matcher(jCas.getDocumentText()); while (m.find()) { Section section = new Section(jCas, m.start(), m.end()); section.setSectionType(BlueUima.SECTION_TYPE_REFERENCES); sections.add(section); } if (sections.size() == 1) { sections.get(0).addToIndexes(); return true; } return false; }
public FeatureStructure createFS(int addr, CASImpl cas) { if (Section_Type.this.useExistingInstance) { // Return eq fs instance if already created FeatureStructure fs = Section_Type.this.jcas.getJfsFromCaddr(addr); if (null == fs) { fs = new Section(addr, Section_Type.this); Section_Type.this.jcas.putJfsFromCaddr(addr, fs); return fs; } return fs; } else return new Section(addr, Section_Type.this); } };
/** Internal - constructor used by generator * @generated * @param addr low level Feature Structure reference * @param type the type of this Feature Structure */ public Section(int addr, TOP_Type type) { super(addr, type); readObject(); }
/** @generated * @param jcas JCas to which this Feature Structure belongs */ public Section(JCas jcas) { super(jcas); readObject(); }