Skip to content

ItalianPhone

Giuseppe Cannella edited this page Feb 19, 2020 · 2 revisions
Type name example
ItalianPhone 02 645566
import com.github.gekomad.regexcollection.ItalianPhone                            
import com.github.gekomad.regexcollection.Validate.validate                       
                                                                                  
assert(validate[ItalianPhone]("""+3902/583725""") == None)                        
assert(validate[ItalianPhone]("""023232323""") == None)                           
assert(validate[ItalianPhone]("""02 645566""") == Some("""02 645566"""))          
assert(validate[ItalianPhone]("""02/583725""") == Some("""02/583725"""))
assert(validate[ItalianPhone]("""02-583725""") == Some("""02-583725"""))                 
Clone this wiki locally