Ejemplo n.º 1
0
 // TODO: Remove warning after API has been finalized
 public override System.Collections.Generic.ICollection <byte[]> GetPayload()
 {
     byte[] bytes = new byte[positions.GetPayloadLength()];
     bytes = positions.GetPayload(bytes, 0);
     System.Collections.Generic.List <byte[]> val = new System.Collections.Generic.List <byte[]>();
     val.Add(bytes);
     return(val);
 }
Ejemplo n.º 2
0
        // TODO: Remove warning after API has been finalized

        public override ICollection <byte[]> GetPayload()
        {
            byte[] bytes = new byte[internalPositions.PayloadLength];
            bytes = internalPositions.GetPayload(bytes, 0);
            var val = new System.Collections.Generic.List <byte[]>();

            val.Add(bytes);
            return(val);
        }
Ejemplo n.º 3
0
        public ICollection <byte[]> GetPayload()
        {
            byte[] bytes = new byte[positions.GetPayloadLength()];
            bytes = positions.GetPayload(bytes, 0);
            List <byte[]> result = new List <byte[]>(1);

            result.Add(bytes);
            return(result);
        }
Ejemplo n.º 4
0
 protected internal virtual void  ProcessPayload(Similarity similarity)
 {
     if (positions.IsPayloadAvailable())
     {
         payload      = positions.GetPayload(payload, 0);
         payloadScore = Enclosing_Instance.Enclosing_Instance.function.CurrentScore(doc, Enclosing_Instance.Enclosing_Instance.term.Field(), spans.Start(), spans.End(), payloadsSeen, payloadScore, similarity.ScorePayload(doc, Enclosing_Instance.Enclosing_Instance.term.Field(), spans.Start(), spans.End(), payload, 0, positions.GetPayloadLength()));
         payloadsSeen++;
     }
     else
     {
         // zero out the payload?
     }
 }
Ejemplo n.º 5
0
 protected internal virtual void  ProcessPayload(Similarity similarity)
 {
     if (positions.IsPayloadAvailable())
     {
         payload       = positions.GetPayload(payload, 0);
         payloadScore += similarity.ScorePayload(Enclosing_Instance.Enclosing_Instance.term.Field(), payload, 0, positions.GetPayloadLength());
         payloadsSeen++;
     }
     else
     {
         //zero out the payload?
     }
 }