11 |
|
{ |
12 |
|
static void Main(string[] args) |
13 |
|
{ |
14 |
+ |
// Setup access to check loaded Granny2 API Version |
15 |
|
Granny2APIVersion _version = new Granny2APIVersion(); |
16 |
|
|
17 |
+ |
// Check if the Loaded API Version Matches |
18 |
|
if (!_version.APIVersionsMatch) |
19 |
|
{ |
20 |
+ |
// the loaded version does not match |
21 |
|
Console.WriteLine("Warning:\n" + |
22 |
|
"\t Loaded Granny2 DLL Version: " + _version.APIVersion.Version + "\n" + |
23 |
|
"\t Expected Version: " + _version.ExpectedAPIVersion.Version); |
24 |
+ |
// return from void to exit application |
25 |
|
return; |
26 |
|
} |
27 |
|
else |
28 |
|
{ |
29 |
+ |
// the loaded version matches |
30 |
|
Console.WriteLine("Loaded granny2.dll: " + _version.APIVersion.Version); |
31 |
|
} |
32 |
+ |
// if we have arrived at this point, the loaded api version matches the what the library was built against |
33 |
|
} |
34 |
|
} |
35 |
|
} |