PageRenderTime 36ms CodeModel.GetById 15ms RepoModel.GetById 0ms app.codeStats 0ms

/indra/newview/llcapabilityprovider.h

https://bitbucket.org/lindenlab/viewer-beta/
C++ Header | 56 lines | 13 code | 4 blank | 39 comment | 0 complexity | 70e723851f262863c99c8dd28c8838fd MD5 | raw file
Possible License(s): LGPL-2.1
  1. /**
  2. * @file llcapabilityprovider.h
  3. * @author Nat Goodspeed
  4. * @date 2009-01-07
  5. * @brief Interface by which to reference (e.g.) LLViewerRegion to obtain a
  6. * capability.
  7. *
  8. * $LicenseInfo:firstyear=2009&license=viewerlgpl$
  9. * Second Life Viewer Source Code
  10. * Copyright (C) 2010, Linden Research, Inc.
  11. *
  12. * This library is free software; you can redistribute it and/or
  13. * modify it under the terms of the GNU Lesser General Public
  14. * License as published by the Free Software Foundation;
  15. * version 2.1 of the License only.
  16. *
  17. * This library is distributed in the hope that it will be useful,
  18. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  19. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  20. * Lesser General Public License for more details.
  21. *
  22. * You should have received a copy of the GNU Lesser General Public
  23. * License along with this library; if not, write to the Free Software
  24. * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  25. *
  26. * Linden Research, Inc., 945 Battery Street, San Francisco, CA 94111 USA
  27. * $/LicenseInfo$
  28. */
  29. #if ! defined(LL_LLCAPABILITYPROVIDER_H)
  30. #define LL_LLCAPABILITYPROVIDER_H
  31. #include "llhost.h"
  32. #include <string>
  33. /// Interface for obtaining a capability URL, given a capability name
  34. class LLCapabilityProvider
  35. {
  36. public:
  37. virtual ~LLCapabilityProvider() {}
  38. /**
  39. * Get a capability URL, given a capability name. Returns empty string if
  40. * no such capability is defined on this provider.
  41. */
  42. virtual std::string getCapability(const std::string& name) const = 0;
  43. /**
  44. * Get host to which to send that capability request.
  45. */
  46. virtual const LLHost& getHost() const = 0;
  47. /**
  48. * Describe this LLCapabilityProvider for logging etc.
  49. */
  50. virtual std::string getDescription() const = 0;
  51. };
  52. #endif /* ! defined(LL_LLCAPABILITYPROVIDER_H) */