ValidationRules Class

Represents the built in Edm validation rules.

Inheritance Hierarchy

System.Object
  Microsoft.Data.Edm.Validation.ValidationRules

Namespace:  Microsoft.Data.Edm.Validation
Assembly:  Microsoft.Data.Edm (in Microsoft.Data.Edm.dll)

Syntax

'Declaration
Public NotInheritable Class ValidationRules
'Usage
public static class ValidationRules
public ref class ValidationRules abstract sealed
[<AbstractClassAttribute>]
[<SealedAttribute>]
type ValidationRules =  class end
public final class ValidationRules

The ValidationRules type exposes the following members.

Fields

  Name Description
Public fieldStatic member BinaryTypeReferenceBinaryMaxLengthNegative Validates that the max length of a binary type is not negative.
Public fieldStatic member BinaryTypeReferenceBinaryUnboundedNotValidForMaxLength Validates that isUnbounded cannot be true if MaxLength is non-null.
Public fieldStatic member CollectionExpressionAllElementsCorrectType Validates that all properties of a collection expression are of the correct type.
Public fieldStatic member ComplexTypeInvalidAbstractComplexType Validates that a complex type is not abstract.
Public fieldStatic member ComplexTypeInvalidPolymorphicComplexType Validates that a complex type does not inherit.
Public fieldStatic member ComplexTypeMustContainProperties Validates that a complex type contains at least one property.
Public fieldStatic member ComposableFunctionImportMustHaveReturnType Validates that if a function import is composable, it must have a return type.
Public fieldStatic member DecimalTypeReferencePrecisionOutOfRange Validates that the precision is between 0 and the max precision of the decimal type.
Public fieldStatic member DecimalTypeReferenceScaleOutOfRange Validates that the scale is between 0 and the precision of the decimal type.
Public fieldStatic member DirectValueAnnotationHasXmlSerializableName Validates that the name of a direct value annotation can safely be serialized as XML.
Public fieldStatic member ElementDirectValueAnnotationFullNameMustBeUnique Validates that no direct value annotations share the same name and namespace.
Public fieldStatic member EntityContainerDuplicateEntityContainerMemberName Validates that there are no duplicate names in an entity container.
Public fieldStatic member EntityContainerElementMustNotHaveKindOfNone Validates an entity container element without other errors must not have kind of none.
Public fieldStatic member EntityReferenceTypeInaccessibleEntityType Validates that the entity type wrapped in this entity reference can be found through the model being validated.
Public fieldStatic member EntitySetAssociationSetNameMustBeValid Validates an association set's name is correct
Public fieldStatic member EntitySetCanOnlyBeContainedByASingleNavigationProperty Validates that an entity set can only have a single navigation property targeting it that has Contains set to true.
Public fieldStatic member EntitySetInaccessibleEntityType Validates that the entity type of an entity set can be found from the model being validated.
Public fieldStatic member EntitySetNavigationMappingMustBeBidirectional Validates that if a navigation property is traversed to another entity set, and then the navigation properties partner is traversed, the destination will be the source entity set.
Public fieldStatic member EntitySetNavigationPropertyMappingMustPointToValidTargetForProperty Validates that the target of a navigation property mapping is valid for the target type of the property.
Public fieldStatic member EntitySetNavigationPropertyMappingsMustBeUnique Validates that no navigation property is mapped to two different entity sets.
Public fieldStatic member EntitySetRecursiveNavigationPropertyMappingsMustPointBackToSourceEntitySet Validates that if a navigation property mapping is of recursive containment, the mapping points back to the source entity set.
Public fieldStatic member EntitySetTypeHasNoKeys Validates that the entity set type has no keys.
Public fieldStatic member EntityTypeDuplicatePropertyNameSpecifiedInEntityKey Validates that there are not duplicate properties in an entity key.
Public fieldStatic member EntityTypeEntityKeyMustBeScalar Validates that all parts of an entity key are scalar.
Public fieldStatic member EntityTypeEntityKeyMustNotBeBinaryBeforeV2 Validates that no part of an entity key is a binary primitive type.
Public fieldStatic member EntityTypeInvalidKeyKeyDefinedInBaseClass Validates that a key is not defined if there is already a key in the base type.
Public fieldStatic member EntityTypeInvalidKeyNullablePart Validates that no part of an entity key is nullable.
Public fieldStatic member EntityTypeKeyMissingOnEntityType Validates that the entity type has a key.
Public fieldStatic member EntityTypeKeyPropertyMustBelongToEntity Validates that all properties in the key of an entity belong to that entity.
Public fieldStatic member EnumMemberValueMustHaveSameTypeAsUnderlyingType Validates that the enumeration value must have the same type as underlying type.
Public fieldStatic member EnumMustHaveIntegerUnderlyingType Raises an error if the underlying type of an enum type is not an integer type.
Public fieldStatic member EnumTypeEnumMemberNameAlreadyDefined Validates that there are not duplicate enum members in an enum.
Public fieldStatic member EnumTypeEnumsNotSupportedBeforeV3 Raises an error if an enum type is found.
Public fieldStatic member FunctionApplicationExpressionParametersMatchAppliedFunction Validates the types of a function application are correct.
Public fieldStatic member FunctionBaseParameterNameAlreadyDefinedDuplicate Validates that a function does not have multiple parameters with the same name.
Public fieldStatic member FunctionImportBindableFunctionImportMustHaveParameters Validates that if a function is bindable, it must have parameters.
Public fieldStatic member FunctionImportComposableFunctionImportCannotBeSideEffecting Validates that if a function is composable, it is not also sideeffecting.
Public fieldStatic member FunctionImportEntitySetExpressionIsInvalid Validates that the entity set of a function import is defined using a path or an entity set reference expression.
Public fieldStatic member FunctionImportEntityTypeDoesNotMatchEntitySet Validates that the function import entity type does not match entity set.
Public fieldStatic member FunctionImportIsBindableNotSupportedBeforeV3 Validates that a function is not bindable.
Public fieldStatic member FunctionImportIsComposableNotSupportedBeforeV3 Validates that a function import is not composable.
Public fieldStatic member FunctionImportIsSideEffectingNotSupportedBeforeV3 Validates that a function import is not sideeffecting.
Public fieldStatic member FunctionImportParametersCannotHaveModeOfNone Validates that no function import parameters have mode of none.
Public fieldStatic member FunctionImportParametersIncorrectTypeBeforeV3 Validates that the type of a function imports parameter is correct.
Public fieldStatic member FunctionImportReturnEntitiesButDoesNotSpecifyEntitySet Validates that the function import returns entities but does not specify entity set.
Public fieldStatic member FunctionImportUnsupportedReturnTypeAfterV1 Validates that a function import has an allowed return type.
Public fieldStatic member FunctionImportUnsupportedReturnTypeV1 Validates that the function import does not support return type version 1.
Public fieldStatic member FunctionOnlyInputParametersAllowedInFunctions Validates that no function parameters are output parameters.
Public fieldStatic member FunctionsNotSupportedBeforeV2 Validates that the functions are not supported before version 2.
Public fieldStatic member IfExpressionAssertCorrectTestType Validates that an if expression has a Boolean condition.
Public fieldStatic member ImmediateValueAnnotationElementAnnotationHasNameAndNamespace Validates that an immediate value annotation that is flagged to be serialized as an element can be serialized safely.
Public fieldStatic member ImmediateValueAnnotationElementAnnotationIsValid Validates that an immediate value annotation has a name and a namespace.
Public fieldStatic member ModelDuplicateEntityContainerName Validates that there are not duplicate properties in an entity key.
Public fieldStatic member ModelDuplicateSchemaElementName Validates every schema element in the current model is unique across all referenced models.
Public fieldStatic member ModelDuplicateSchemaElementNameBeforeV3 Validates every schema element in the current model (except for entity containers) is unique across all referenced models.
Public fieldStatic member NamedElementNameIsNotAllowed Validates that an element name matches the allowed pattern of names according to the CSDL spec.
Public fieldStatic member NamedElementNameIsTooLong Validates that an element name is not too long according to the CSDL spec.
Public fieldStatic member NamedElementNameMustNotBeEmptyOrWhiteSpace Validates that a name is not empty or whitespace.
Public fieldStatic member NavigationPropertyAssociationEndNameIsValid Validates that an association end name is valid.
Public fieldStatic member NavigationPropertyAssociationNameIsValid Validates that an association name is valid.
Public fieldStatic member NavigationPropertyContainsTargetNotSupportedBeforeV3 Validates that ContainsTarget is not set prior to V3.
Public fieldStatic member NavigationPropertyCorrectType Validates that the type of a navigation property corresponds to the other end of the association and the multiplicity of the other end.
Public fieldStatic member NavigationPropertyDependentEndMultiplicity Validates that if the dependent properties are equivalent to the key of the dependent end, the multiplicity of the dependent end cannot be 1 Validates multiplicity of the dependent end according to the following rules: 0..1, 1 - if dependent properties represent the dependent end key. * - if dependent properties don't represent the dependent end key.
Public fieldStatic member NavigationPropertyDependentPropertiesMustBelongToDependentEntity Validates that all dependent properties of a navigation property belong to the dependent entity type.
Public fieldStatic member NavigationPropertyDuplicateDependentProperty Validates that the dependent properties of a navigation property contain no duplicates.
Public fieldStatic member NavigationPropertyEndWithManyMultiplicityCannotHaveOperationsSpecified Validates that the navigation property does not have both a multiplicity of many and an OnDelete operation.
Public fieldStatic member NavigationPropertyEntityMustNotIndirectlyContainItself Validates that if an entity does not directly contain itself, it cannot contain itself through a containment loop.
Public fieldStatic member NavigationPropertyInvalidOperationMultipleEndsInAssociation Validates that only one end of an association has an OnDelete operation.
Public fieldStatic member NavigationPropertyInvalidToPropertyInRelationshipConstraintBeforeV2 Validates that all dependent properties are a subset of the dependent entity types key.
Public fieldStatic member NavigationPropertyPrincipalEndMultiplicity Validates multiplicity of the principal end: 0..1 - if some dependent properties are nullable, 1 - if some dependent properties are not nullable. * - not allowed.
Public fieldStatic member NavigationPropertyTypeMismatchRelationshipConstraint Validates that each pair of properties between the dependent properties and the principal ends key are of the same type.
Public fieldStatic member NavigationPropertyWithNonRecursiveContainmentSourceMustBeFromOne Validates that if a navigation property has ContainsTarget = true and the target entity type is defferent than the declaring type of the property, then the multiplicity of the source of navigation is One.
Public fieldStatic member NavigationPropertyWithRecursiveContainmentSourceMustBeFromZeroOrOne Validates that if a navigation property has ContainsTarget = true and the target entity type is the same as the declaring type of the property, then the multiplicity of the source of navigation is Zero-Or-One. This depends on there being a targetting cycle. Because of the rule EntitySetNavigationMappingMustBeBidirectional, we know that either this is always true, or there will be an error
Public fieldStatic member NavigationPropertyWithRecursiveContainmentTargetMustBeOptional Validates that if a navigation property has ContainsTarget = true and the target entity type is the same as the declaring type of the property, then the multiplicity of the target of navigation is 0..1 or Many. This depends on there being a targetting cycle. Because of the rule EntitySetNavigationMappingMustBeBidirectional, we know that either this is always true, or there will be an error
Public fieldStatic member OnlyEntityTypesCanBeOpen Open types are supported only on entity types.
Public fieldStatic member OpenTypesNotSupported Opens different types that are supported only in version 1.2 and after version 2.0.
Public fieldStatic member PrimitiveTypeMustNotHaveKindOfNone Validates a primitive type without other errors must not have kind of none.
Public fieldStatic member PrimitiveValueValidForType Validates that if a primitive value declares a type, the value is acceptable for the type.
Public fieldStatic member PropertyMustNotHaveKindOfNone Validates a property without other errors must not have kind of none.
Public fieldStatic member PropertyValueBindingValueIsCorrectType Validates that the value of a property value binding is the correct type.
Public fieldStatic member RecordExpressionPropertiesMatchType Validates that if a value record expression declares a type, the property types are correct.
Public fieldStatic member RowTypeBaseTypeMustBeNull Validates that a row type does not have a base type.
Public fieldStatic member RowTypeMustContainProperties Validates that a row type contains at least one property.
Public fieldStatic member SchemaElementMustNotHaveKindOfNone Validates a schema element without other errors must not have kind of none.
Public fieldStatic member SchemaElementNamespaceIsNotAllowed Validates that an element namespace matches the allowed pattern of namespaces according to the CSDL spec.
Public fieldStatic member SchemaElementNamespaceIsTooLong Validates that an element namespace is not too long according to the CSDL spec.
Public fieldStatic member SchemaElementNamespaceMustNotBeEmptyOrWhiteSpace Validates that an element namespace is not empty or whitespace.
Public fieldStatic member SchemaElementSystemNamespaceEncountered Validates that an element namespace is not a reserved system namespace.
Public fieldStatic member SpatialTypeReferencesNotSupportedBeforeV3 References to EDM spatial types are not supported before version 3.0.
Public fieldStatic member StreamTypeReferencesNotSupportedBeforeV3 References to EDM stream type are not supported before version 3.0.
Public fieldStatic member StringTypeReferenceStringMaxLengthNegative Validates that the max length of a string is not negative.
Public fieldStatic member StringTypeReferenceStringUnboundedNotValidForMaxLength Validates that IsUnbounded cannot be true if MaxLength is non-null.
Public fieldStatic member StructuralPropertyInvalidPropertyType Validates that the property is of an allowed type.
Public fieldStatic member StructuralPropertyInvalidPropertyTypeConcurrencyMode Validates that if the concurrency mode of a property is fixed, the type is primitive.
Public fieldStatic member StructuralPropertyNullableComplexType Validates that any property with a complex type is not nullable.
Public fieldStatic member StructuredTypeBaseTypeMustBeSameKindAsDerivedKind Validates that the base type of a complex type is complex, and the base type of an entity type is an entity.
Public fieldStatic member StructuredTypeInaccessibleBaseType Validates that the base type of a structured type can be found from the model being validated.
Public fieldStatic member StructuredTypeInvalidMemberNameMatchesTypeName Validates that a type does not have a property with the same name as that type.
Public fieldStatic member StructuredTypePropertiesDeclaringTypeMustBeCorrect Validates that the declaring type of a property contains that property.
Public fieldStatic member StructuredTypePropertyNameAlreadyDefined Validates that there are not duplicate properties in a type.
Public fieldStatic member TemporalTypeReferencePrecisionOutOfRange Validates that the precision is between 0 and the max precision of the temporal type.
Public fieldStatic member TermMustNotHaveKindOfNone Validates a term without other errors must not have kind of none.
Public fieldStatic member TypeAnnotationAssertMatchesTermType Validates that a type annotation implements its term type properly.
Public fieldStatic member TypeAnnotationInaccessibleTerm Validates that a vocabulary annotations term can be found through the model containing the annotation.
Public fieldStatic member TypeMustNotHaveKindOfNone Validates a type without other errors must not have kind of none.
Public fieldStatic member TypeReferenceInaccessibleSchemaType Validates that a type reference refers to a type that can be found through the model being validated.
Public fieldStatic member ValueAnnotationAssertCorrectExpressionType Validates that if a value annotation declares a type, the expression for that annotation has the correct type.
Public fieldStatic member ValueAnnotationInaccessibleTerm Validates that a vocabulary annotations term can be found through the model containing the annotation.
Public fieldStatic member ValueTermsNotSupportedBeforeV3 Value terms are not supported before EDM 3.0.
Public fieldStatic member VocabularyAnnotatableNoDuplicateAnnotations Validates that there are no annotations that share the same term and qualifier.
Public fieldStatic member VocabularyAnnotationInaccessibleTarget Validates that a vocabulary annotations target can be found through the model containing the annotation.
Public fieldStatic member VocabularyAnnotationsNotSupportedBeforeV3 Validates a vocabulary annotations are not supported before EDM 3.0.

Top

Remarks

No content here will be updated; please do not add material here.

Thread Safety

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

See Also

Reference

Microsoft.Data.Edm.Validation Namespace