<img height="1" width="1" style="display:none;" alt="" src="https://px.ads.linkedin.com/collect/?pid=4138537&amp;fmt=gif">
Skip to content
English
  • There are no suggestions because the search field is empty.

.isValidDate()

Method checks that the given string is a valid date.

Description of the method

 

Description: isValidDate method checks that the given string is a valid date. It takes the expected date format as a parameter. Date format is defined with Java SimpleDateFormat syntax (http://docs.oracle.com/javase/7/docs...ateFormat.html)
Available for: string
Parameters: -
Return type: boolean

Example

 

Context: HeaderType1
OCL: self.dateTimeString.isValidDate("yyyy-MM-dd'T'HH:mm:ss.SSSXXX")
Description: The example rule checks that the value in dateString field is valid ISO 8601 datetime.