コード例 #1
0
ファイル: CBUUIDExtensions.cs プロジェクト: mcmap4/32feet
        internal static Guid ToGuid(this CBUUID uuid)
        {
            byte[] b = new byte[16];

            switch (uuid.Data.Length)
            {
            case 2:
                b = new Guid("0x00000000, 0x0000, 0x1000, 0x80, 0x00, 0x00, 0x80, 0x5F, 0x9B, 0x34, 0xFB").ToByteArray();
                Marshal.Copy(uuid.Data.Bytes, b, 0, (int)uuid.Data.Length);

                break;

            default:

                Marshal.Copy(uuid.Data.Bytes, b, 0, (int)uuid.Data.Length);
                break;
            }

            return(new Guid(b));
        }
コード例 #2
0
ファイル: CBUUIDExtensions.cs プロジェクト: mcmap4/32feet
 internal static CBUUID ToCBUUID(this Guid guid)
 {
     return(CBUUID.FromBytes(guid.ToByteArray()));
 }
コード例 #3
0
ファイル: GuidWrapper.cs プロジェクト: tondat/xamarin-macios
 public void ScanForPeripherals(CBUUID serviceUuid)
 {
     ScanForPeripherals(new [] { serviceUuid }, null as NSDictionary);
 }
コード例 #4
0
ファイル: GuidWrapper.cs プロジェクト: tondat/xamarin-macios
 public void ScanForPeripherals(CBUUID serviceUuid, NSDictionary options)
 {
     ScanForPeripherals(new [] { serviceUuid }, options);
 }
コード例 #5
0
ファイル: GuidWrapper.cs プロジェクト: tondat/xamarin-macios
 public void RetrievePeripherals(CBUUID peripheralUuid)
 => throw new NotSupportedException();
コード例 #6
0
 public void RetrievePeripherals(CBUUID peripheralUuid)
 {
     RetrievePeripherals(new [] { peripheralUuid });
 }