Example #1
0
        public Pin(int parentNodeId, StateEnum state = StateEnum.OFF, PolarityEnum polarity = PolarityEnum.POS, string name = "")
        {
            PinId = UniqueIdGenerator.GeneratePinId();
            Name  = string.IsNullOrEmpty(name)
                ? $"{GetType().Name}{nameof(Pin)}{PinId}"
                : $"{name}{PinId}";
            State    = state;
            Polarity = polarity;

            ParentNodeId = parentNodeId;
        }