Gets the paths connected to an exit @param dir exit direction @return set of paths connected to that exit
(final String dir)
| 201 | * @return set of paths connected to that exit |
| 202 | */ |
| 203 | public HashSet<Path> getExit(final String dir) { |
| 204 | HashSet<Path> ret = new HashSet<>(); |
| 205 | for (final Path path : paths) { |
| 206 | if (path.getExit(this).equals(dir)) { |
| 207 | ret.add(path); |
| 208 | } |
| 209 | } |
| 210 | return ret; |
| 211 | } |
| 212 | |
| 213 | /** |
| 214 | * Gets the paths to a place |
no outgoing calls