PageRenderTime 17ms CodeModel.GetById 13ms app.highlight 2ms RepoModel.GetById 1ms app.codeStats 0ms

/indra/newview/llversioninfo.h

https://bitbucket.org/lindenlab/viewer-beta/
C++ Header | 72 lines | 17 code | 12 blank | 43 comment | 0 complexity | cca23a2dd419b78702e1b0ee850b5b25 MD5 | raw file
 1/** 
 2 * @file llversioninfo.h
 3 * @brief Routines to access the viewer version and build information
 4 * @author Martin Reddy
 5 *
 6 * $LicenseInfo:firstyear=2009&license=viewerlgpl$
 7 * Second Life Viewer Source Code
 8 * Copyright (C) 2010, Linden Research, Inc.
 9 * 
10 * This library is free software; you can redistribute it and/or
11 * modify it under the terms of the GNU Lesser General Public
12 * License as published by the Free Software Foundation;
13 * version 2.1 of the License only.
14 * 
15 * This library is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
18 * Lesser General Public License for more details.
19 * 
20 * You should have received a copy of the GNU Lesser General Public
21 * License along with this library; if not, write to the Free Software
22 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
23 * 
24 * Linden Research, Inc., 945 Battery Street, San Francisco, CA  94111  USA
25 * $/LicenseInfo$
26 */
27
28#ifndef LL_LLVERSIONINFO_H
29#define LL_LLVERSIONINFO_H
30
31#include <string>
32
33///
34/// This API provides version information for the viewer.  This
35/// includes access to the major, minor, patch, and build integer
36/// values, as well as human-readable string representations. All
37/// viewer code that wants to query the current version should 
38/// use this API.
39///
40class LLVersionInfo
41{
42public:
43	/// return the major verion number as an integer
44	static S32 getMajor();
45
46	/// return the minor verion number as an integer
47	static S32 getMinor();
48
49	/// return the patch verion number as an integer
50	static S32 getPatch();
51
52	/// return the build number as an integer
53	static S32 getBuild();
54
55	/// return the full viewer version as a string like "2.0.0.200030"
56	static const std::string &getVersion();
57
58	/// return the viewer version as a string like "2.0.0"
59	static const std::string &getShortVersion();
60
61	/// return the viewer version and channel as a string
62	/// like "Second Life Release 2.0.0.200030"
63	static const std::string &getChannelAndVersion();
64
65	/// return the channel name, e.g. "Second Life"
66	static const std::string &getChannel();
67	
68	/// reset the channel name used by the viewer.
69	static void resetChannel(const std::string& channel);
70};
71
72#endif