aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Tests/Common/TestHelpers.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Tests/Common/TestHelpers.cs')
-rw-r--r--OpenSim/Tests/Common/TestHelpers.cs21
1 files changed, 21 insertions, 0 deletions
diff --git a/OpenSim/Tests/Common/TestHelpers.cs b/OpenSim/Tests/Common/TestHelpers.cs
index 57da802..a684d72 100644
--- a/OpenSim/Tests/Common/TestHelpers.cs
+++ b/OpenSim/Tests/Common/TestHelpers.cs
@@ -114,6 +114,27 @@ namespace OpenSim.Tests.Common
114 } 114 }
115 115
116 /// <summary> 116 /// <summary>
117 /// Parse a UUID stem into a full UUID.
118 /// </summary>
119 /// <remarks>
120 /// Yes, this is completely inconsistent with ParseTail but this is probably a better way to do it,
121 /// UUIDs are conceptually not hexadecmial numbers.
122 /// The fragment will come at the start of the UUID. The rest will be 0s
123 /// </remarks>
124 /// <returns></returns>
125 /// <param name='frag'>
126 /// A UUID fragment that will be parsed into a full UUID. Therefore, it can only contain
127 /// cahracters which are valid in a UUID, except for "-" which is currently only allowed if a full UUID is
128 /// given as the 'fragment'.
129 /// </param>
130 public static UUID ParseStem(string stem)
131 {
132 string rawUuid = stem.PadRight(32, '0');
133
134 return UUID.Parse(rawUuid);
135 }
136
137 /// <summary>
117 /// Parse tail section into full UUID. 138 /// Parse tail section into full UUID.
118 /// </summary> 139 /// </summary>
119 /// <param name="tail"></param> 140 /// <param name="tail"></param>