You are researching officer communities way late in the game, throwing stuff at the wall to see if it will stick - that’s how it appears to readers trying to make sense of your posts and help you out. In hindsight, applicants should slog through this kind of research first, thinking through how they might like to spend 5-8 years on active duty, then reverse engineer to explore the commissioning paths that best suit.
First.
A Diving Officer is found in this community, which is Restricted Line (RL), more on that shortly. EDO here means Engineering Duty, not EOD, Explosive Ordnance Disposal.
Other officer communities have dive-qualified officers, such as SEAL, EDO.
Then there are enlisted Navy Divers, personnel who perform as divers in various warfare communities.
Second. Unrestricted Line (URL) officer communities are the main warfare communities, surface, aviation, submarine, SEAL, EOD, etc. Those officers can serve in or out of their communities, and can serve in command at sea as well as shore in an unrelated field. A naval aviator can command an operational squadron but also non-aviation units ashore. In that sense, they are restricted.
RL officers are line officers who specialize in their community area, may command in that area, and typically always work in their job field. These include EDO, IW (Cyber, Intel, Meteorological, etc.), HR, etc.
Staff Corps officers are the professional staffs of the Navy: Medical, Nurse, Dental, Medical Service, Civil Engineering (CEC), JAG, etc. As with RL, they work in their job field and may command in their field.
Each of these has various paths to commissioning or transferring to that community. USNA and NROTC mission is to produce Navy (and Marine Corps) URL officers for the Fleet and Corps. A small number out of USNA may go RL or Staff, especially if a pre-comm med DQ precludes them from going URL.
At a certain point in their career, usually after they have earned their community warfare qualification, officers may competitively apply to another community. A SWO officer might apply to go HR. A submarine officer might apply for the Navy Law Education Program and then move into JAG Corps. An aviator might apply for intel. There are some “deals,” out there, such as SWO-ED, where it’s guaranteed if you perform well and gain SWO qual, you’ll be sent to ED program - these deals change with the needs of the Navy. Or, while in college, an aspiring Navy officer might do their homework in what academics are required and apply for Navy OCS during senior year in college. Everyone going to OCS knows their path before coming in. OCS and its counterpart ODS, both in Newport, RI, handle most of the RL and Staff direct accessions.
There are also special college paths for NUPOC (no NROTC required, good $$) and CEC. I won’t even go into the Health Professional Scholarship programs or the joint military medical school at USUHS.
I’ll leave it to you to research Navy sites for the paths to various communities. The “MyNavyHR” site has career paths for each community and general info. Navy officer recruiting sites do too.