We need you! We're working hard on the next version of Developer Fusion -
Let us know what you think we should be up to!
- namespace System.Security.Policy
- {
- internal interface IBuiltInEvidence
- {
- int OutputToBuffer(char[] buffer, int position, bool verbose);
-
-
- int InitFromBuffer(char[] buffer, int position);
-
- int GetRequiredSize(bool verbose);
- }
-
- static internal class BuiltInEvidenceHelper
- {
- internal const char idApplicationDirectory = (char)0;
- internal const char idStrongName = (char)2;
- internal const char idZone = (char)3;
- internal const char idUrl = (char)4;
- internal const char idWebPage = (char)5;
- internal const char idSite = (char)6;
- internal const char idPermissionRequestEvidence = (char)7;
- internal const char idGac = (char)9;
-
- static internal void CopyIntToCharArray(int value, char[] buffer, int position)
- {
- buffer[position] = (char)((value >> 16) & 65535);
- buffer[position + 1] = (char)((value)&65535);
- }
-
- static internal int GetIntFromCharArray(char[] buffer, int position)
- {
- int value = (int)buffer[position];
- value = value << 16;
- value += (int)buffer[position + 1];
- return value;
- }
-
- static internal void CopyLongToCharArray(long value, char[] buffer, int position)
- {
- buffer[position] = (char)((value >> 48) & 65535);
- buffer[position + 1] = (char)((value >> 32) & 65535);
- buffer[position + 2] = (char)((value >> 16) & 65535);
- buffer[position + 3] = (char)((value)&65535);
- }
-
- static internal long GetLongFromCharArray(char[] buffer, int position)
- {
- long value = (long)buffer[position];
- value = value << 16;
- value += (long)buffer[position + 1];
- value = value << 16;
- value += (long)buffer[position + 2];
- value = value << 16;
- value += (long)buffer[position + 3];
- return value;
- }
- }
- }