Exemple #1
0
        /// <summary>
        ///     Converts the specified interface data.
        /// </summary>
        /// <param name="interfaceData">The interface data.</param>
        /// <returns>IComInterfaceData.</returns>
        public IComInterfaceData Convert(ClrMd.ComInterfaceData interfaceData)
        {
            if (interfaceData == null)
            {
                return(null);
            }
            var item = new ComInterfaceDataAdapter(this, interfaceData);

            return(Cache.GetOrAdd <IComInterfaceData>(interfaceData, () => item, () => item.Setup()));
        }
Exemple #2
0
 /// <summary>
 ///     Initializes a new instance of the <see cref="ComInterfaceData" /> class.
 /// </summary>
 /// <param name="comInterfaceData">The COM interface data.</param>
 /// <exception cref="System.ArgumentNullException">comInterfaceData</exception>
 /// <inheritdoc />
 public ComInterfaceData(ClrMd.ComInterfaceData comInterfaceData)
 {
     _comInterfaceData = comInterfaceData ?? throw new ArgumentNullException(nameof(comInterfaceData));
 }