

def write(self):
    q = {
        
    }
    if (self._host_name is not None):
        Util.set_by_path(q, 'HostName', self._host_name)
    if (self._password is not None):
        Util.set_by_path(q, 'Password', self._password)
    if (len(self._ssh_keys) > 0):
        Util.set_by_path(notes, 'SSHKey.PublicKey', '\n'.join(self._ssh_keys))
    if (self._ip_address is not None):
        Util.set_by_path(q, 'UserIPAddress', self._ip_address)
    if (self._default_route is not None):
        Util.set_by_path(q, 'UserSubnet.DefaultRoute', self._default_route)
    if (self._network_mask_len is not None):
        Util.set_by_path(q, 'UserSubnet.NetworkMaskLen', self._network_mask_len)
    if (0 < len(self._scripts)):
        notes = []
        for script in self._scripts:
            notes.append({
                'ID': script._id(),
            })
        Util.set_by_path(q, 'Notes', notes)
    path = (('/disk/' + self._disk_id) + '/config')
    self._client.request('PUT', path, q)
    return self

dataset/ETHPy150Open sakura-internet/saklient.python/saklient/cloud/resources/diskconfig.py DiskConfig.write/VarMisuse@87/110 `q`->`notes`