示例#1
0
        public IndexDocument CreateDocument(ContentItem item)
        {
            var d = new IndexDocument();

            d.ID = item.ID;
            d.Tokens["LuceneDocument"] = CreateLuceneDocument(item);
            return(d);
        }
示例#2
0
        public void Update(IndexDocument document)
        {
            var doc = (Document)document.Tokens["LuceneDocument"];

            foreach (var field in document.Values)
            {
                doc.Add(new Field(field.Name, field.Value, field.Stored ? Field.Store.YES : Field.Store.NO, field.Analyzed ? Field.Index.ANALYZED : Field.Index.NO));
            }

            WriteToIndex(document.ID, doc);
        }
示例#3
0
		public void Update(IndexDocument document)
		{
		}
示例#4
0
		public void Update(IndexDocument document)
		{
			var doc = (Document)document.Tokens["LuceneDocument"];
			foreach (var field in document.Values)
				doc.Add(new Field(field.Name, field.Value, field.Stored ? Field.Store.YES : Field.Store.NO, field.Analyzed ? Field.Index.ANALYZED : Field.Index.NO));

			WriteToIndex(document.ID, doc);
		}
示例#5
0
		public IndexDocument CreateDocument(ContentItem item)
		{
			var d = new IndexDocument();
			d.ID = item.ID;
			d.Tokens["LuceneDocument"] = CreateLuceneDocument(item);
			return d;
		}
示例#6
0
 public void Update(IndexDocument document)
 {
 }