Exemplo n.º 1
0
        /// <summary>
        /// Get schema location for pin
        /// </summary>
        /// <param name="proxy">E3.series IPinInterface COM proxy object</param>
        /// <returns>Schema location struct or null if not placed</returns>
        public static SchemaLocationStruct?GetSchemaLocationStruct(this E3PinProxy proxy)
        {
            object x       = null;
            object y       = null;
            object grid    = null;
            int    sheetId = proxy.GetSchemaLocation(ref x, ref y, ref grid);

            if (sheetId == 0)
            {
                return(null);
            }

            return(new SchemaLocationStruct((double)x, (double)y, grid as string, sheetId));
        }
Exemplo n.º 2
0
 /// <summary>
 /// Check for pin is placed on the sheet
 /// </summary>
 /// <param name="proxy">E3.series IPinInterface COM proxy object</param>
 /// <returns></returns>
 public static bool IsPlaced(this E3PinProxy proxy) => proxy.GetSchemaLocationStruct().HasValue;