private Event <FeatureDiff> CreateDiff(FeaturePair <TGeometry, TAttributes> pair)
 => new Event <FeatureDiff>()
 {
     AggregateId = pair.AggregateId,
     Version     = pair.Version,
     EventData   = _diffPatch.Diff(pair.ExistingAggregate?.Data, pair.NewFeature)
 };
Exemple #2
0
        public string GetProperty(string AutomationIdDotProperty)
        {
            string[]    parts   = AutomationIdDotProperty.Split('.');
            FeaturePair feature = FindFeature(parts[0]);

            if (feature != null)
            {
                return(feature.GetProperty().Get(parts[1]));
            }
            return(string.Empty);
        }
Exemple #3
0
        /*
         * private void Notify(int count, int total)
         * {
         *  // could be an issue if no one is listening, but there should be a listener by the time this is called
         *  if (_OnCountReceived != null)
         *      _OnCountReceived(count, total);
         * }
         *
         * public event GiveCount OnCountReceived
         * {
         *  add
         *  {
         *      _OnCountReceived += value;
         *  }
         *  remove
         *  {
         *      _OnCountReceived -= value;
         *  }
         * }
         */

        private void initFeatures()
        {
            for (int i = 0; i < fts.Length - 1; i += 2)
            {
                FeaturePair temp = new FeaturePair();
                temp.P1 = fts[i];
                temp.P2 = fts[i + 1];
                features.Add(temp);
            }

            totalsList = new List <double> [features.Count];
            for (int j = 0; j < totalsList.Length; j++)
            {
                totalsList[j] = new List <double>();
            }

            totals = new double[features.Count];
        }
Exemple #4
0
 public void AddFeature(FeaturePair pair)
 {
     Features.Add(pair);
 }
Exemple #5
0
        /*
        private void Notify(int count, int total)
        {
            // could be an issue if no one is listening, but there should be a listener by the time this is called
            if (_OnCountReceived != null)
                _OnCountReceived(count, total);
        }

        public event GiveCount OnCountReceived
        {
            add
            {
                _OnCountReceived += value;
            }
            remove
            {
                _OnCountReceived -= value;
            }
        }
        */
        private void initFeatures()
        {
            for (int i = 0; i < fts.Length - 1; i += 2)
            {
                FeaturePair temp = new FeaturePair();
                temp.P1 = fts[i];
                temp.P2 = fts[i + 1];
                features.Add(temp);
            }

            totalsList = new List<double>[features.Count];
            for (int j = 0; j < totalsList.Length; j++)
            {
                totalsList[j] = new List<double>();
            }

            totals = new double[features.Count];
        }
 private static bool IsNotNoop(FeaturePair <TGeometry, TAttributes> pair)
 => pair.Operation != Operation.NoOperation;
Exemple #7
0
        private void initFeatures()
        {
            for (int i = 0; i < fts.Length - 1; i+=2)
            {
                FeaturePair temp = new FeaturePair();
                temp.P1 = fts[i];
                temp.P2 = fts[i + 1];
                features.Add(temp);
            }

            totals = new float[features.Count];
        }