CF Validation



Can some one give me a brief explanation of how custom field validation works through the code.
I tracked back as far as lib/ :: _AddCustomFieldValue;

However I am not sure how/where the following happens:
unless ( $cf->ValidateValue( $args{‘Value’} ) ) {
return ( 0, $self->loc(“Invalid value for custom field”) );

I cannot find ValidateValue any where !!??

The reason for my question is the need to create my own CF validation pattern I would like to extend
To also include hours and minutes,
so values to my custom field should be yyyy-mm-dd hh:mm

Is this possible and how?