docs: def add(self, properties):
          """
          Add a faked NIC resource.
  
          Parameters:
  
            properties (dict):
              Resource properties.
  
              Special handling and requirements for certain properties:
  
              * 'element-id' will be auto-generated with a unique value across
                all instances of this resource type, if not specified.
              * 'element-uri' will be auto-generated based upon the element ID,
                if not specified.
              * 'class' will be auto-generated to 'nic',
                if not specified.
              * Either 'network-adapter-port-uri' (for backing ROCE adapters) or
                'virtual-switch-uri'(for backing OSA or Hipersockets adapters) is
                required to be specified.
              * 'device-number' will be auto-generated with a unique value
                within the partition in the range 0x8000 to 0xFFFF, if not
                specified.
  
              This method also updates the 'nic-uris' property in the parent
              faked Partition resource, by adding the URI for the faked NIC
              resource.
  
              This method also updates the 'connected-vnic-uris' property in the
              virtual switch referenced by 'virtual-switch-uri' property,
              and sets it to the URI of the faked NIC resource.
  
          Returns:
            :class:`zhmcclient_mock.FakedNic`: The faked NIC resource.
  
          Raises:
            :exc:`zhmcclient_mock.InputError`: Some issue with the input
              properties.
          """
          new_nic = super(FakedNicManager, self).add(properties)
  
          partition = self.parent
  
          # For OSA-backed NICs, reflect the new NIC in the virtual switch
          if 'virtual-switch-uri' in new_nic.properties:
              vswitch_uri = new_nic.properties['virtual-switch-uri']
              # Even though the URI handler when calling this method ensures that
              # the vswitch exists, this method can be called by the user as
              # well, so we have to handle the possibility that it does not
              # exist:
              try:
                  vswitch = self.hmc.lookup_by_uri(vswitch_uri)
              except KeyError:
                  raise InputError("The virtual switch specified in the "
                                   "'virtual-switch-uri' property does not "
                                   "exist: {!r}".format(vswitch_uri))
              connected_uris = vswitch.properties['connected-vnic-uris']
              if new_nic.uri not in connected_uris:
                  connected_uris.append(new_nic.uri)
  
          # Create a default device-number if not specified
          if 'device-number' not in new_nic.properties:
              devno = partition.devno_alloc()
              new_nic.properties['device-number'] = devno
  
          # Reflect the new NIC in the partition
          assert 'nic-uris' in partition.properties
          partition.properties['nic-uris'].append(new_nic.uri)
  
          return new_nic