2 * Copyright 2004 The WebRTC Project Authors. All rights reserved.
4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree.
11 #ifndef WEBRTC_LIBJINGLE_XMPP_SASLHANDLER_H_
12 #define WEBRTC_LIBJINGLE_XMPP_SASLHANDLER_H_
22 // Creates mechanisms to deal with a given mechanism
27 // Intended to be subclassed
28 virtual ~SaslHandler() {}
30 // Should pick the best method according to this handler
31 // returns the empty string if none are suitable
32 virtual std::string ChooseBestSaslMechanism(const std::vector<std::string> & mechanisms, bool encrypted) = 0;
34 // Creates a SaslMechanism for the given mechanism name (you own it
36 // If not handled, return NULL.
37 virtual SaslMechanism * CreateSaslMechanism(const std::string & mechanism) = 0;
42 #endif // WEBRTC_LIBJINGLE_XMPP_SASLHANDLER_H_