public IReadOnlyList<Contingency> Matches {get;}
Public ReadOnly Property Matches As IReadOnlyList(Of Contingency)
public IReadOnlyList<Contingency> Matches {get;}
Public ReadOnly Property Matches As IReadOnlyList(Of Contingency)
public void ValidateContingentValues(FeatureClass parcels, string zoningFieldName = "Zone", string taxCodeFieldName = "TaxCode") { using (RowBuffer rowBuffer = parcels.CreateRowBuffer()) { // Insert values in a row buffer rowBuffer[zoningFieldName] = "Business"; rowBuffer[taxCodeFieldName] = "TaxB"; // Validate contingency values of the parcels' row ContingencyValidationResult contingencyValidationResult = parcels.ValidateContingencies(rowBuffer); // Valid contingencies IReadOnlyList<Contingency> matchedContingencies = contingencyValidationResult.Matches; if (matchedContingencies.Count > 0) { // Create a row with valid contingency values parcels.CreateRow(rowBuffer); } // Invalid contingencies IReadOnlyList<ContingencyViolation> violatedContingencies = contingencyValidationResult.Violations; foreach (ContingencyViolation contingencyViolation in violatedContingencies) { ContingencyViolationType violationType = contingencyViolation.Type; Contingency violatedContingency = contingencyViolation.Contingency; } } }
Target Platforms: Windows 11, Windows 10