To answer your question yes................If you jailbreak your phone it *technically* voids your warranty, but so long as you rstore to stock settings, and do not tell Apple that you jailbroke then yes.............Your warranty is untouched.
I have been jailbreaking for years, and have got my iPhone replaced a few times along with my iPod Touch 4G. All you have to do to maintain your warranty beofe taking in for service is to unjailbreak(restore) and update to the latest iOS.
As longs you you restore your phone, then Apple will never now that you jailbroke it. But if you send in/take in a jailbroken iPhone they will know it was jialbroken and deny you service (unless you happen to get a Geneus that doesnt care....which is slim).