예제 #1
0
        MinutiaMatcher DequeueMatcher(PreparedProbe probe)
        {
            MinutiaMatcher matcher = DequeueMatcher();

            matcher.SelectProbe(probe.ProbeIndex);
            return(matcher);
        }
예제 #2
0
        public PreparedProbe Prepare(Template probe)
        {
            PreparedProbe  prepared = new PreparedProbe();
            MinutiaMatcher matcher  = DequeueMatcher();

            try
            {
                matcher.BuildIndex(probe, prepared.ProbeIndex);
            }
            finally
            {
                EnqueueMatcher(matcher);
            }
            return(prepared);
        }
예제 #3
0
        MinutiaMatcher DequeueMatcher()
        {
            MinutiaMatcher matcher = null;

            lock (Matchers)
                if (Matchers.Count > 0)
                {
                    matcher = Matchers.Dequeue();
                }
            if (matcher == null)
            {
                matcher = ParameterSet.ClonePrototype(MinutiaMatcher);
            }
            return(matcher);
        }
예제 #4
0
 void EnqueueMatcher(MinutiaMatcher matcher)
 {
     lock (Matchers)
         Matchers.Enqueue(matcher);
 }