If finding swallowtail eggs and caterpillars is too difficult, another option is to collect a live female and set her up in a cage to lay eggs. This is a picture of an indra swallowtail female in a cage laying eggs on parsley (Lomatium scabrum). This is exactly how you would set up an anise swallowtail female to lay eggs as well. Place parsley in a bouquet and place a cage over it. Place the leaves of the parsley adjacent to the sun-exposed side of the cage so that when the butterfly flies toward that part of the cage, she will run into the plant and may lay eggs on it.
