Set a property on an object. Adds the new property and
triggers change notification if the property doesn't
already exist.
777467
function set (obj, key, val) {
	  if (Array.isArray(obj)) {
	    obj.splice(key, 1, val);
	    return val
	  }
	  if (hasOwn(obj, key)) {
	    obj[key] = val;
	    return
	  }
	  var ob = obj.__ob__;
	  if (obj._isVue || (ob && ob.vmCount)) {
	    "development" !== 'production' && warn(
	      'Avoid adding reactive properties to a Vue instance or its root $data ' +
	      'at runtime - declare it upfront in the data option.'
	    );
	    return
	  }
	  if (!ob) {
	    obj[key] = val;
	    return
	  }
	  defineReactive$$1(ob.value, key, val);
	  ob.dep.notify();
	  return val
	}
801619
def setProperty(self, name, value):
        '''
        
        '''
        self._push(self._driver.setProperty, (name, value))
743537
@Override
    public void addProperty(Property property) {
        properties.add(property);
        property.addPropertyChangeListener(this);
        buildModel();
    }
343478
function set(key, value) {
        if (global.localStorage) {
            var _value;
            try {
                _value = JSON.stringify(value);
                global.localStorage.setItem(key, _value);
                $(exports).triggerHandler("change", [key, value]);
            } catch (e) {
                console.error("[PreferenceManager] Failed to write preference value of key: " + key);
            }
        }
    }
84118
public void addProperty(ReadableProperty<R> property) {
        property.addValueChangeListener(changeAdapter);
        properties.add(property);
        updateFromProperties();
    }
564961
def add_object(self, obj, properties=()):
        """"""
        self._objects.add(obj)
        self._properties |= properties
        self._pairs.update((obj, p) for p in properties)
1162178
function set(name, val) {
  // If the name is an object
  var key;
  if (typeof name === 'object') {
    // Iterate over its properties
    for (key in name) {
      if (name.hasOwnProperty(key)) {
        // Set each one
        set(key, name[key]);
      }
    }
  } else {
  // Otherwise, save to settings
    settings[name] = val;
  }
}
649966
function(value) {
      const oldValue = this[subScriptName];

      // TODO: add custom comparison options function
      if (oldValue === value) {
        return;
      }

      // Clear old child model
      if (oldValue && oldValue instanceof Model && oldValue.parentModel === this) {
        this.removeModelChild(oldValue);
      }

      this[subScriptName] = value;

      // Update new child model
      if (value && value instanceof Model) {
        this.addModelChild(name, value);
      }

      let po = this.propertyOptions[name];

      let onChange = po.onChange;
      let doNotNotify = po.doNotNotify;
      let skipNotify = false;

      if (onChange) {
        skipNotify = onChange(oldValue, value);
      }

      if (this.propertyChange) {
        this.propertyChange(name, oldValue, value);
      }

      if (!this.deserializing && !skipNotify && !doNotNotify) {
        this.notify(name, this, value, this.getChangeDescriptor(name, oldValue, value));
      }
    }
1048730
function(object, setters, property) {

        _.each(setters, function(setter, name) {
            object.__addSetter(property, name, setter);
        });
    }
627761
def _set(self, obj, value):
        """"""
        if value not in self.lenum:
            raise ValueError("Not a valid value: %s" % value)

        type(obj).__dict__[self.propname].__set__(obj, value)
477505
function (newValue) {
                    // and no inheritance is involved
                    if (this === self) {
                      // notify the method but ...
                      var value = oldValue;
                      updateValue(newValue);
                      // ... do not update the get value
                      oldValue = value;
                    } else {
                      // with inheritance, simply set the property
                      // as if it was a regular assignment operation
                      setValue(this, prop, newValue);
                    }
                  }
495377
public void setProperty(String property, Object newValue) {
        /** @todo we should check if we have the property with the metaClass instead of try/catch  */
        try {
            super.setProperty(property, newValue);
        }
        catch (MissingPropertyException e) {
            setVariable(property, newValue);
        }
    }
2737
public void setProperty(final Object object, Object newValue) {
        AccessPermissionChecker.checkAccessPermission(field);
        final Object goalValue = DefaultTypeTransformation.castToType(newValue, field.getType());

        if (isFinal()) {
            throw new GroovyRuntimeException("Cannot set the property '" + name + "' because the backing field is final.");
        }
        try {
            field.set(object, goalValue);
        } catch (IllegalAccessException ex) {
            throw new GroovyRuntimeException("Cannot set the property '" + name + "'.", ex);
        }
    }
1029307
function _set_property(itemsObject, name, value) {
  const nameArray = name.split(".");
  if (nameArray[1]) {
    itemsObject[nameArray[0]][nameArray[1]] = value;
  } else {
    itemsObject[name] = value;
  }
}
933231
def add(cls, name, value):
        """"""
        attr = cls(value)
        attr._name = name
        setattr(cls, name, attr)
689091
def on_change(self, value):
        ''''''
        self._modifier(self.inst, self.prop, value)
261327
public static void setGroovyObjectProperty(Object newValue, GroovyObject object, String property) {
        object.setProperty(property, newValue);
    }