PepperDash / Essentials

The Essentials Application Framework Libraries
MIT License
133 stars 77 forks source link

[FEATURE]-Add `dmTx4kz100c` as valid device typename #1009

Closed jonnyarndt closed 1 year ago

jonnyarndt commented 2 years ago

Is your feature request related to a problem? Please describe. Essentials does not recognize device type dmTx4kz100c as a valid device type. However, it does recognize dmTx4k100c as valid type.

Describe the solution you'd like Please add dmTx4kz100c as a valid typename generating the same class as the dmTx4k100c.

Describe alternatives you've considered None

Additional context Tested against Essentials v1.9.5.

TrevorPayne commented 1 year ago

Marking this as complete - is present in most recent release version of essentials.

public static BasicDmTxControllerBase GetDmTxForChassisWithoutIpId(string key, string name, string typeName, DMInput dmInput)
        {
            // Other things removed for clarity
            if (typeName.StartsWith("dmtx4kz100"))
                return new DmTx4kz100Controller(key, name, new DmTx4kz100C1G(dmInput));
            // Other things removed for clarity

            return null;
        }
public static BasicDmTxControllerBase GetDmTxForChassisWithIpId(string key, string name, string typeName, uint ipid, DMInput dmInput)
        {
            // Other Things removed for clarity
            if (typeName.StartsWith("dmtx4kz100"))
                return new DmTx4kz100Controller(key, name, new DmTx4kz100C1G(ipid, dmInput));
            // Other Things removed for clarity

            return null;
        }