Files
zmVault/assembly-objects.md
T

1.2 KiB

id, aliases, tags, title
id aliases tags title
destiny/fleeting
topic/automation
topic/estimating
topic/software
type/idea
Assembly Objects

Assembly Objects

public class GangableReceptacle : IGangableDevice, IUtilizationEquipment
{
    public int Gangs { get; }
    
    ...
}

public class GangableSwitch : IGangableDevice
...

public class DeviceBox : IOutletBox
{
    private List<IGangableDevice> _contents;

    public void Add(IGangableDevice device)
    {
        _contents.Add(device);
    }
    
    public int GetGangs()
    {
        int gangs = 0;
        foreach (device in _contents)
        {
            gangs += device.Gangs
        }
        return gangs
    }

    public List<Item> Resolve()
    {
        // Check content types and resolve by specifications
        // or raise error if not possible
        // (e.g. incompatible devices)
    }
}
- type: switchboard
  parents: 1
  children: 0..
  primary-rating: amperes

- type: transfer-switch
  parents: 2
  children: 1
  primary-rating: amperes

- type: transformer
  parents: 1
  children: 1..
  primary-rating: volt-amperes
  
- type: generator
  parents: 0
  children: 1..
  primary-rating: watts