C# Class DomainNotificationHelper.Validation.AssertionConcern

Datei anzeigen Open project: andrebaltieri/DomainNotificationHelper.Validation

Public Methods

Method Description
AssertAreEquals ( string value, string match, string message ) : DomainNotificationHelper.Events.DomainNotification

Assert if the values are equals

AssertEmailIsValid ( string email, string message ) : DomainNotificationHelper.Events.DomainNotification

Assert if the string value is an valid email

AssertGuidIsNotEmpty ( System.Guid value, string message ) : DomainNotificationHelper.Events.DomainNotification

Check if the Guid value is different of Guid.Empty

AssertIsGreaterOrEqualThan ( decimal value1, decimal value2, string message ) : DomainNotificationHelper.Events.DomainNotification

Assert if the decimal value 01 is bigger than decimal value 02

AssertIsGreaterOrEqualThan ( int value1, int value2, string message ) : DomainNotificationHelper.Events.DomainNotification

Assert if the integer value 01 is bigger than or equals integer value 02

AssertIsGreaterThan ( decimal value1, decimal value2, string message ) : DomainNotificationHelper.Events.DomainNotification

Assert if the decimal value 01 is bigger than decimal value 02

AssertIsGreaterThan ( int value1, int value2, string message ) : DomainNotificationHelper.Events.DomainNotification

Assert if the integer value 01 is bigger than integer value 02

AssertIsNull ( object object1, string message ) : DomainNotificationHelper.Events.DomainNotification

Assert if the object is null

AssertLength ( string stringValue, int minimum, int maximum, string message ) : DomainNotificationHelper.Events.DomainNotification

Assert if the string value respects the minimum and maximum limits size

AssertMatches ( string pattern, string stringValue, string message ) : DomainNotificationHelper.Events.DomainNotification

Assert if the string value matches with the Regex Pattern

AssertNotEmpty ( string stringValue, string message ) : DomainNotificationHelper.Events.DomainNotification

Assert if the string value is not null, empty or white spaces

AssertNotNull ( object object1, string message ) : DomainNotificationHelper.Events.DomainNotification

Assert if the object is not null

AssertRegexMatch ( string value, string regex, string message ) : DomainNotificationHelper.Events.DomainNotification

Assert if the string value matches with Regex Pattern

AssertTrue ( bool boolValue, string message ) : DomainNotificationHelper.Events.DomainNotification

Assert if the validation statement or boolean value is true

AssertUrlIsValid ( string url, string message ) : DomainNotificationHelper.Events.DomainNotification

Assert if the string value is an valid url

IsSatisfiedBy ( ) : bool

Private Methods

Method Description
NotifyAll ( IEnumerable notifications ) : void

Method Details

AssertAreEquals() public static method

Assert if the values are equals
public static AssertAreEquals ( string value, string match, string message ) : DomainNotificationHelper.Events.DomainNotification
value string String value
match string String value to match
message string Message to return if Assert occurred
return DomainNotificationHelper.Events.DomainNotification

AssertEmailIsValid() public static method

Assert if the string value is an valid email
public static AssertEmailIsValid ( string email, string message ) : DomainNotificationHelper.Events.DomainNotification
email string String value
message string Message to return if Assert occurred
return DomainNotificationHelper.Events.DomainNotification

AssertGuidIsNotEmpty() public static method

Check if the Guid value is different of Guid.Empty
public static AssertGuidIsNotEmpty ( System.Guid value, string message ) : DomainNotificationHelper.Events.DomainNotification
value System.Guid Not nullable Guid
message string Message to return if Assert occurred
return DomainNotificationHelper.Events.DomainNotification

AssertIsGreaterOrEqualThan() public static method

Assert if the decimal value 01 is bigger than decimal value 02
public static AssertIsGreaterOrEqualThan ( decimal value1, decimal value2, string message ) : DomainNotificationHelper.Events.DomainNotification
value1 decimal Decimal value 01
value2 decimal Decimal value 02
message string Message to return if Assert occurred
return DomainNotificationHelper.Events.DomainNotification

AssertIsGreaterOrEqualThan() public static method

Assert if the integer value 01 is bigger than or equals integer value 02
public static AssertIsGreaterOrEqualThan ( int value1, int value2, string message ) : DomainNotificationHelper.Events.DomainNotification
value1 int Integer value 01
value2 int Integer value 02
message string Message to return if Assert occurred
return DomainNotificationHelper.Events.DomainNotification

AssertIsGreaterThan() public static method

Assert if the decimal value 01 is bigger than decimal value 02
public static AssertIsGreaterThan ( decimal value1, decimal value2, string message ) : DomainNotificationHelper.Events.DomainNotification
value1 decimal Decimal value 01
value2 decimal Decimal value 02
message string Message to return if Assert occurred
return DomainNotificationHelper.Events.DomainNotification

AssertIsGreaterThan() public static method

Assert if the integer value 01 is bigger than integer value 02
public static AssertIsGreaterThan ( int value1, int value2, string message ) : DomainNotificationHelper.Events.DomainNotification
value1 int Integer value 01
value2 int Integer value 02
message string Message to return if Assert occurred
return DomainNotificationHelper.Events.DomainNotification

AssertIsNull() public static method

Assert if the object is null
public static AssertIsNull ( object object1, string message ) : DomainNotificationHelper.Events.DomainNotification
object1 object Object to check
message string Message to return if Assert occurred
return DomainNotificationHelper.Events.DomainNotification

AssertLength() public static method

Assert if the string value respects the minimum and maximum limits size
public static AssertLength ( string stringValue, int minimum, int maximum, string message ) : DomainNotificationHelper.Events.DomainNotification
stringValue string String value
minimum int Minimun limit size
maximum int Maximun limit size
message string Message to return if Assert occurred
return DomainNotificationHelper.Events.DomainNotification

AssertMatches() public static method

Assert if the string value matches with the Regex Pattern
public static AssertMatches ( string pattern, string stringValue, string message ) : DomainNotificationHelper.Events.DomainNotification
pattern string Regex Pattern
stringValue string String value
message string Message to return if Assert occurred
return DomainNotificationHelper.Events.DomainNotification

AssertNotEmpty() public static method

Assert if the string value is not null, empty or white spaces
public static AssertNotEmpty ( string stringValue, string message ) : DomainNotificationHelper.Events.DomainNotification
stringValue string String Value
message string Message to return if Assert occurred
return DomainNotificationHelper.Events.DomainNotification

AssertNotNull() public static method

Assert if the object is not null
public static AssertNotNull ( object object1, string message ) : DomainNotificationHelper.Events.DomainNotification
object1 object Object to check
message string Message to return if Assert occurred
return DomainNotificationHelper.Events.DomainNotification

AssertRegexMatch() public static method

Assert if the string value matches with Regex Pattern
public static AssertRegexMatch ( string value, string regex, string message ) : DomainNotificationHelper.Events.DomainNotification
value string String value
regex string Regex Pattern to match
message string Message to return if Assert occurred
return DomainNotificationHelper.Events.DomainNotification

AssertTrue() public static method

Assert if the validation statement or boolean value is true
public static AssertTrue ( bool boolValue, string message ) : DomainNotificationHelper.Events.DomainNotification
boolValue bool Validation statement or boolean value
message string Message to return if Assert occurred
return DomainNotificationHelper.Events.DomainNotification

AssertUrlIsValid() public static method

Assert if the string value is an valid url
public static AssertUrlIsValid ( string url, string message ) : DomainNotificationHelper.Events.DomainNotification
url string String value
message string Message to return if Assert occurred
return DomainNotificationHelper.Events.DomainNotification

IsSatisfiedBy() public static method

public static IsSatisfiedBy ( ) : bool
return bool