Describe the process by which vaccines induce immunity.