Returns all implementations for the given WebSocket. @param ws WebSocket @param ann annotation (can be null) @return result of check @throws QueryException query exception @throws IOException I/O exception
(final WebSocket ws, final Annotation ann)
| 176 | * @throws IOException I/O exception |
| 177 | */ |
| 178 | public ArrayList<WsFunction> findWs(final WebSocket ws, final Annotation ann) |
| 179 | throws QueryException, IOException { |
| 180 | final ArrayList<WsFunction> funcs = new ArrayList<>(); |
| 181 | for(final WebModule mod : cache(ws.context).values()) { |
| 182 | for(final WsFunction func : mod.wsFunctions()) { |
| 183 | if(func.matches(ann, ws.path)) funcs.add(func); |
| 184 | } |
| 185 | } |
| 186 | Collections.sort(funcs); |
| 187 | return funcs; |
| 188 | } |
| 189 | |
| 190 | /** |
| 191 | * Returns the WebSocket function that matches the current request. |