Agrobacterium is probably one of the most famous and oldest genetic engineers. It injects a marked piece of its “Ti-Plasmid” into plant cells. The inserted sequence codes for a growth hormone (to make the plant produce this “tumors”, but it does not have much to do with cancer. Just unregulated growth of these plant cells) and a gene to make the plant produce a special nutrient, that many other bacteria cannot digest. Thus it programs the plant to give it shelter and food. Smart bug.
For the GFP plant, a lab strain of this bacterium was taken. The marked piece of DNA, that it usually injects into plants was deleted (disarmed strain) and later replaced with the GFP gene. So the only gene it could possibly inject is the sequence we provide it with in pGreenII.