Examples of removeField()


Examples of org.apache.bcel.generic.ClassGen.removeField()

        ClassGen cg = getClassGen();
        Field field = cg.containsField(name);
        if (field == null) {
            return false;
        } else {
            cg.removeField(field);
            m_isModified = true;
            m_isHashCurrent = false;
            return true;
        }
    }
View Full Code Here

Examples of org.apache.flink.types.Record.removeField()

    int oldLen = 0;

    // Create filled record and remove field from the middle
    record = new Record(this.origVal1, this.origVal2);
    record.addField(this.origVal3);
    record.removeField(1);

    assertTrue(record.getNumFields() == 2);

    StringValue recVal1 = record.getField(0, StringValue.class);
    IntValue recVal2 = record.getField(1, IntValue.class);
View Full Code Here

Examples of org.apache.jackrabbit.mongomk.impl.model.MongoNode.removeField()

        if (!exists) {
            throw new NotFoundException(path + " @rev" + baseRevisionId);
        }
        node = existCommand.getNode();
        node.removeField("_id");
        if (addToMap) {
            pathNodeMap.put(path, node);
        }
        return node;
    }
View Full Code Here

Examples of org.apache.lucene.document.Document.removeField()

      }

      if (text != null) {
        // Overwrite the content with a shortend summary
        String resSummary = RegainToolkit.createSummaryFromContent(text, 200);
        document.removeField("summary");
        if (resSummary != null) {
          document.add(new Field("summary", resSummary, Field.Store.NO, Field.Index.NOT_ANALYZED));
          document.add(new Field("summary", CompressionTools.compressString(resSummary), Field.Store.YES));
          // write back the transformed document
          setHitDocument(index, document);
View Full Code Here

Examples of org.apache.lucene.document.Document.removeField()

      }

      if (text != null) {
        // Overwrite the content with a shortend summary
        String resSummary = RegainToolkit.createSummaryFromContent(text, 200);
        document.removeField("summary");
        if (resSummary != null) {
          //System.out.println("resSummary " + resSummary);
          document.add(new Field("summary", resSummary, Field.Store.NO, Field.Index.NOT_ANALYZED));
          document.add(new Field("summary", CompressionTools.compressString(resSummary), Field.Store.YES));
View Full Code Here

Examples of org.apache.lucene.document.Document.removeField()

         
          for (String val : vals)
          {
          storedVals.add(val);
          }
          doc.removeField(facetHandler.getName());
         
          for (String val : storedVals){
            doc.add(new Field(facetHandler.getName(),
                      val,
                      Field.Store.NO,
View Full Code Here

Examples of org.apache.lucene.document.Document.removeField()

                      for(Document subDoc : docsList) {
                        writer.addDocument(subDoc);
                      }
                      */
                    }
                    doc.removeField("packID");

                    if (random.nextInt(5) == 2) {
                      if (VERBOSE) {
                        //System.out.println(Thread.currentThread().getName() + ": buffer del id:" + packID);
                      }
View Full Code Here

Examples of org.apache.lucene.document.Document.removeField()

                    delCount.addAndGet(subDocs.subIDs.size());
                  }
                  toDeleteSubDocs.clear();
                }
                if (addedField != null) {
                  doc.removeField(addedField);
                }
              } catch (Throwable t) {
                System.out.println(Thread.currentThread().getName() + ": hit exc");
                t.printStackTrace();
                failed.set(true);
View Full Code Here

Examples of org.apache.lucene.document.Document.removeField()

    assertTrue(r1.isCurrent());

    String id10 = r1.document(10).getField("id").stringValue();
   
    Document newDoc = r1.document(10);
    newDoc.removeField("id");
    newDoc.add(new Field("id", Integer.toString(8000), Store.YES, Index.NOT_ANALYZED));
    writer.updateDocument(new Term("id", id10), newDoc);
    assertFalse(r1.isCurrent());

    IndexReader r2 = writer.getReader();
View Full Code Here

Examples of org.apache.lucene.document.Document.removeField()

    assertTrue(r1.isCurrent());

    String id10 = r1.document(10).getField("id").stringValue();
   
    Document newDoc = r1.document(10);
    newDoc.removeField("id");
    newDoc.add(new Field("id", Integer.toString(8000), Store.YES, Index.NOT_ANALYZED));
    writer.updateDocument(new Term("id", id10), newDoc);
    assertFalse(r1.isCurrent());

    IndexReader r2 = writer.getReader();
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.