Yes, if they follow you into your drive way,and see you get out of the car. Or if they are down the street, and see you get out of the car, as they are pulling up. Now, if you were out of the car, and they were no where to be seen, that might be a different story.
If you had done something that warrants a ticket before you pulled into your driveway, s/he can do that. If you haven't done anything to warrant it, then s/he has no right to do that. An attorney would be best placed to assist you with this.