TIKA-1208 : Migrate Mime detector functions from Any23