private static byte[] ToByteArray(string value) { char[] charArray = value.ToCharArray(); if (charArray.Length % 2 != 0) { throw new RemotingException(string.Format((IFormatProvider)CultureInfo.CurrentCulture, Environment.GetResourceString("Remoting_SOAPInteropxsdInvalid"), (object)"xsd:hexBinary", (object)value)); } byte[] numArray = new byte[charArray.Length / 2]; for (int index = 0; index < charArray.Length / 2; ++index) { numArray[index] = (byte)((uint)SoapHexBinary.ToByte(charArray[index * 2], value) * 16U + (uint)SoapHexBinary.ToByte(charArray[index * 2 + 1], value)); } return(numArray); }
// Token: 0x0600565A RID: 22106 RVA: 0x0013139C File Offset: 0x0012F59C private static byte[] ToByteArray(string value) { char[] array = value.ToCharArray(); if (array.Length % 2 != 0) { throw new RemotingException(string.Format(CultureInfo.CurrentCulture, Environment.GetResourceString("Remoting_SOAPInteropxsdInvalid"), "xsd:hexBinary", value)); } byte[] array2 = new byte[array.Length / 2]; for (int i = 0; i < array.Length / 2; i++) { array2[i] = SoapHexBinary.ToByte(array[i * 2], value) * 16 + SoapHexBinary.ToByte(array[i * 2 + 1], value); } return(array2); }