clockwerk-opensim-stable – Blame information for rev 1
?pathlinks?
Rev | Author | Line No. | Line |
---|---|---|---|
1 | vero | 1 | /* |
2 | * Copyright (c) Contributors, http://opensimulator.org/ |
||
3 | * See CONTRIBUTORS.TXT for a full list of copyright holders. |
||
4 | * |
||
5 | * Redistribution and use in source and binary forms, with or without |
||
6 | * modification, are permitted provided that the following conditions are met: |
||
7 | * * Redistributions of source code must retain the above copyright |
||
8 | * notice, this list of conditions and the following disclaimer. |
||
9 | * * Redistributions in binary form must reproduce the above copyright |
||
10 | * notice, this list of conditions and the following disclaimer in the |
||
11 | * documentation and/or other materials provided with the distribution. |
||
12 | * * Neither the name of the OpenSimulator Project nor the |
||
13 | * names of its contributors may be used to endorse or promote products |
||
14 | * derived from this software without specific prior written permission. |
||
15 | * |
||
16 | * THIS SOFTWARE IS PROVIDED BY THE DEVELOPERS ``AS IS'' AND ANY |
||
17 | * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED |
||
18 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE |
||
19 | * DISCLAIMED. IN NO EVENT SHALL THE CONTRIBUTORS BE LIABLE FOR ANY |
||
20 | * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES |
||
21 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; |
||
22 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND |
||
23 | * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT |
||
24 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS |
||
25 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
||
26 | */ |
||
27 | |||
28 | using System; |
||
29 | using OpenMetaverse; |
||
30 | |||
31 | namespace OpenSim.Framework |
||
32 | { |
||
33 | /// <summary> |
||
34 | /// Information about a users session |
||
35 | /// </summary> |
||
36 | public class UserAgentData |
||
37 | { |
||
38 | /// <summary> |
||
39 | /// The UUID of the users avatar (not the agent!) |
||
40 | /// </summary> |
||
41 | private UUID UUID; |
||
42 | |||
43 | /// <summary> |
||
44 | /// The session ID for the user (also the agent ID) |
||
45 | /// </summary> |
||
46 | private UUID sessionID; |
||
47 | |||
48 | /// <summary> |
||
49 | /// The "secure" session ID for the user |
||
50 | /// </summary> |
||
51 | /// <remarks>Not very secure. Dont rely on it for anything more than Linden Lab does.</remarks> |
||
52 | private UUID secureSessionID; |
||
53 | |||
54 | /// <summary> |
||
55 | /// The IP address of the user |
||
56 | /// </summary> |
||
57 | private string agentIP = String.Empty; |
||
58 | |||
59 | /// <summary> |
||
60 | /// The port of the user |
||
61 | /// </summary> |
||
62 | private uint agentPort; |
||
63 | |||
64 | /// <summary> |
||
65 | /// Is the user online? |
||
66 | /// </summary> |
||
67 | private bool agentOnline; |
||
68 | |||
69 | /// <summary> |
||
70 | /// A unix timestamp from when the user logged in |
||
71 | /// </summary> |
||
72 | private int loginTime; |
||
73 | |||
74 | /// <summary> |
||
75 | /// When this agent expired and logged out, 0 if still online |
||
76 | /// </summary> |
||
77 | private int logoutTime; |
||
78 | |||
79 | /// <summary> |
||
80 | /// Region ID the user is logged into |
||
81 | /// </summary> |
||
82 | private UUID regionID; |
||
83 | |||
84 | /// <summary> |
||
85 | /// Region handle of the current region the user is in |
||
86 | /// </summary> |
||
87 | private ulong regionHandle; |
||
88 | |||
89 | /// <summary> |
||
90 | /// The position of the user within the region |
||
91 | /// </summary> |
||
92 | private Vector3 currentPos; |
||
93 | |||
94 | /// <summary> |
||
95 | /// Current direction the user is looking at |
||
96 | /// </summary> |
||
97 | private Vector3 currentLookAt = Vector3.Zero; |
||
98 | |||
99 | /// <summary> |
||
100 | /// The region the user logged into initially |
||
101 | /// </summary> |
||
102 | private UUID originRegionID; |
||
103 | |||
104 | public virtual UUID ProfileID |
||
105 | { |
||
106 | get { return UUID; } |
||
107 | set { UUID = value; } |
||
108 | } |
||
109 | |||
110 | public virtual UUID SessionID |
||
111 | { |
||
112 | get { return sessionID; } |
||
113 | set { sessionID = value; } |
||
114 | } |
||
115 | |||
116 | public virtual UUID SecureSessionID |
||
117 | { |
||
118 | get { return secureSessionID; } |
||
119 | set { secureSessionID = value; } |
||
120 | } |
||
121 | |||
122 | public virtual string AgentIP |
||
123 | { |
||
124 | get { return agentIP; } |
||
125 | set { agentIP = value; } |
||
126 | } |
||
127 | |||
128 | public virtual uint AgentPort |
||
129 | { |
||
130 | get { return agentPort; } |
||
131 | set { agentPort = value; } |
||
132 | } |
||
133 | |||
134 | public virtual bool AgentOnline |
||
135 | { |
||
136 | get { return agentOnline; } |
||
137 | set { agentOnline = value; } |
||
138 | } |
||
139 | |||
140 | public virtual int LoginTime |
||
141 | { |
||
142 | get { return loginTime; } |
||
143 | set { loginTime = value; } |
||
144 | } |
||
145 | |||
146 | public virtual int LogoutTime |
||
147 | { |
||
148 | get { return logoutTime; } |
||
149 | set { logoutTime = value; } |
||
150 | } |
||
151 | |||
152 | public virtual UUID Region |
||
153 | { |
||
154 | get { return regionID; } |
||
155 | set { regionID = value; } |
||
156 | } |
||
157 | |||
158 | public virtual ulong Handle |
||
159 | { |
||
160 | get { return regionHandle; } |
||
161 | set { regionHandle = value; } |
||
162 | } |
||
163 | |||
164 | public virtual Vector3 Position |
||
165 | { |
||
166 | get { return currentPos; } |
||
167 | set { currentPos = value; } |
||
168 | } |
||
169 | |||
170 | /* 2008-08-28-tyre: Not really useful |
||
171 | public virtual float PositionX |
||
172 | { |
||
173 | get { return currentPos.X; } |
||
174 | set { currentPos.X = value; } |
||
175 | } |
||
176 | |||
177 | public virtual float PositionY |
||
178 | { |
||
179 | get { return currentPos.Y; } |
||
180 | set { currentPos.Y = value; } |
||
181 | } |
||
182 | |||
183 | public virtual float PositionZ |
||
184 | { |
||
185 | get { return currentPos.Z; } |
||
186 | set { currentPos.Z = value; } |
||
187 | } |
||
188 | */ |
||
189 | |||
190 | public virtual Vector3 LookAt |
||
191 | { |
||
192 | get { return currentLookAt; } |
||
193 | set { currentLookAt = value; } |
||
194 | } |
||
195 | |||
196 | public virtual UUID InitialRegion |
||
197 | { |
||
198 | get { return originRegionID; } |
||
199 | set { originRegionID = value; } |
||
200 | } |
||
201 | |||
202 | } |
||
203 | } |