In addition to the answer provided by CardMechanic which is spot on, note that you don't HAVE to get a Shimano replacement, there are other brands that will also work in it's place.Many entry level derailleurs are also sold with removable hangers to work with both direct mount and hanger mount derailleurs.
Also to further illustrate the difference:
Long cage derailleur without hanger:
Short Cage derailleur with hanger:
Shimano uses a 2 to 1 pull ratio on its derailleurs and drivetrain parts while Sram uses a 1 to 1 on most parts, but does offer some entry level stuff in 2 to 1 such as the MRX series.
Sunrace also uses a Shimano compatible 2 to 1 ratio as well so any of their 7 speed rear derailleurs would likely work as well.
Further more you may also note that while this is a direct mount derailleur, the silver portion it bolts to is a frame hanger and is also replaceable should the need ever rise. You would just need to know the model of the frame and year to find a replacement, but the one you have looks to be straight. They are made to avoid damage to the frame should your derailleur come in contact with a rock or other debris. Welcome to the fold and happy riding!