Saute onion in butter in a skillet for a few minutes until tender. Add crabmeat and let it heat through. Sprinkle the bottom of the pie shell with Parmesan cheese, then place crab and onion mixture in pie shell. Place grated cheese on top of the crabmeat mixture. Mix eggs, cream, salt, and cayenne pepper. Slowly pour mixture over ingredients in pie shell. Bake on the top rack of the oven at 375 degrees until done, about 25 minutes. Let cool before slicing and serving.