protected void handleCapabilities ( HttpResponse response ) { allowedMethods = unmodifiableSet ( stream ( response . getHeaders ( "Allow" ) ) . filter ( x -> x . getName ( ) . equals ( "Allow" ) ) . flatMap ( x -> stream ( x . getElements ( ) ) ) . map ( x -> x . getName ( ) ) . collect ( toSet ( ) ) ) ; }
Handles allowed HTTP methods and other capabilities reported by the server .