ViewVC Help
View File | Revision Log | Show Annotations | Download File | View Changeset | Root Listing
root/RomCheater/trunk/RomCheater.Core/GuidTools.cs
Revision: 527
Committed: Wed Jun 5 08:09:59 2013 UTC (9 years ago) by william
File size: 747 byte(s)
Log Message:

File Contents

# Content
1 using System;
2 using System.Collections.Generic;
3 using System.Linq;
4 using System.Text;
5
6 namespace RomCheater.Core
7 {
8 public static class GuidTools
9 {
10 public static Guid IncrementGuid(Guid guid)
11 {
12 byte[] guidBytes = guid.ToByteArray();
13 guidBytes[guidBytes.Length - 1]++; // increment the search guid by 1
14 Guid t_guid = new Guid(guidBytes);
15 return t_guid;
16 }
17 public static Guid DecrementGuid(Guid guid)
18 {
19 byte[] guidBytes = guid.ToByteArray();
20 guidBytes[guidBytes.Length - 1]--; // increment the search guid by 1
21 Guid t_guid = new Guid(guidBytes);
22 return t_guid;
23 }
24 }
25 }