Don't hardcode supported STOMP versions but loop through StompVersions

This commit is contained in:
Ville Skyttä 2015-07-13 23:13:41 +03:00 committed by Clebert Suconic
parent 5d95b8193e
commit 6199d4ee11
1 changed files with 6 additions and 1 deletions

View File

@ -379,7 +379,12 @@ class StompProtocolManager implements ProtocolManager<StompFrameInterceptor>, No
public String getSupportedVersionsAsString()
{
return "v" + StompVersions.V1_0 + " v" + StompVersions.V1_1 + " v" + StompVersions.V1_2;
String versions = "";
for (StompVersions version : StompVersions.values())
{
versions += " v" + version;
}
return versions.substring(1);
}
public String getVirtualHostName()