implemented doule-dispatch type validator structure