Your question seems better answered by an off-grid solar interest group, since you seem to be creating a power generation station out of your shed. Not sure what your full requirements are, but I will try to answer from what I know.
From your question, it seems that you are only interested in accessing 120VAC household current from the shed. Then, yes, you will need to connect to the shed's transfer switch with a full 20A cord, or whatever is the maximum to get full power safely to the trailer. All internal shed wiring on the AC side needs to match amperes needed. Automatic switching would be done on the 120VAC lines, just like the units used for houses which switch between emergency outdoor generators and the utility provider. They are not cheap. In your case, the utility provider is the solar system and its inverter. I imagine that the shed's generator is expected to kick in once the solar powered batteries have expired. However, the rub is that you want to keep 12V lead acid batteries preferably at no less than 70% charge. Repeatedly going to anything less than 50% charge and your batteries will soon die. Therefore the transfer switch has to be smart enough to hand over the power to the generator at the appropriate voltage.
However, like others have mentioned, you need to plan you power needs before expanding your solar system. For example a 1000W, 12V appliance requires 83 Amps to run (1000/12). A 12V battery rated at 120Ah will run your appliance for 86 minutes at best. But, then, don't run your batteries to less than 50% meaning you get 43 minutes of run time.
My experience is that solar is a convenience, a talking point, for dry campers and that a generator is a must for glamping or CPAP.
If it were me, for solar assist, I would go for a couple sets of portable 12V solar panels and a couple of extra batteries for the trailer. I could stick the panels in the shed when I'm done. A remote start for that generator in the shed would be nice. If the generator is a Honda EU2000is or EU3000is, convert it to dual fuel propane and get a big propane tank for it. My 2 cents (1.28 US).