set userdata for the item
559774
function set_userdata($name, $value){
		if ($this->userdata === false)
			$this->userdata = array();

		$this->userdata[$name]=$value;
	}
980736
function readGetUserItemData(message, tokens) {
	message.userName = protocol.decodeString(tokens[1]);
	readGetItemData(message, tokens.slice(2));
}
1343683
def _set(self, jsonData) :
        """"""
        
        self["username"] = jsonData["user"]
        self["active"] = jsonData["active"]
        self["extra"] = jsonData["extra"]
        try:
            self["changePassword"] = jsonData["changePassword"]
        except Exception as e:
            pass
            # self["changePassword"] = ""
        
        try :
            self["password"] = jsonData["passwd"]
        except KeyError :
            self["password"] = ""

        self.URL = "%s/user/%s" % (self.connection.URL, self["username"])
891314
def setData(self, index, value, role=QtCore.Qt.UserRole):
        
        if role == QtCore.Qt.EditRole:
            if isinstance(value, QtCore.QVariant):
                value = value.toPyObject()
            elif isinstance(value, QtCore.QString):
                value = str(value)
            self.model.setVerifiedValue(index.row(), self._headers[index.column()], value)
            self.countChanged.emit()
        elif role == QtCore.Qt.UserRole:
            row = index.row()
            if row == -1:
                row = self.rowCount() -1
            self.model.overwriteParam(row, value)
        return True
1170884
def set_data(self, data):
        
        for name in self._fields:
            setattr(self, name, data.get(name))
        return self
851861
public function setUserData(User $user)
    {
        $userVarArray = get_object_vars($user);

        foreach ($userVarArray as $key => $value) {
            if ($value !== null) {
                $this->{$key} = $value;
            }
        }
    }
583452
def _set(self, item, value):
        
        if item not in object.__getattribute__(self, "_protectedItems") \
                and item[0] != "_":
            keys = object.__getattribute__(self, "_data")
            if not hasattr(value, '__call__'):
                keys[item] = value
                return value
            if hasattr(value, '__call__') and item in keys:
                raise Exception("""Cannot set model data to a function, same \
name exists in data""")
        return object.__setattr__(self, item, value)
1195018
function setData(el, attr, val, prefix) {
    if (prefix === undefined) {
      prefix = 'wookmark-';
    }
    el.setAttribute('data-' + prefix + attr, val);
  }
467991
public function setData($data)
	{
		if( is_null($data) )
		{
			$data = [];
		}

		if( $data instanceof stdClass )
		{
			$data = [$data];
		}

		if( is_array($data) )
		{
			$data = $this->checkItems($data);
			$this->data = $data;
		}

		$this->data = (array) $data;

		if(empty($this->type) && ! empty($this->data[0]))
		{
			$this->type = $this->data[0]->getType();
		}
	}
509946
def set_item(self,item):
        ""
        self.item = self.x.process_one(item)
        yield None
        self.item = None
276627
private function setData()
    {
        $data = $this->config->get('auth.external_concrete5', '');
        $authUrl = $this->urlResolver->resolve(['/ccm/system/authentication/oauth2/external_concrete5/attempt_auth']);
        $attachUrl = $this->urlResolver->resolve(['/ccm/system/authentication/oauth2/external_concrete5/attempt_attach']);
        $baseUrl = $this->urlResolver->resolve(['/']);
        $path = $baseUrl->getPath();
        $path->remove('index.php');
        $name = trim((string) array_get($data, 'name', t('External concrete5')));

        $this->set('data', $data);
        $this->set('authUrl', $authUrl);
        $this->set('attachUrl', $attachUrl);
        $this->set('baseUrl', $baseUrl);
        $this->set('assetBase', $baseUrl->setPath($path));
        $this->set('name', $name);
        $this->set('user', $this->app->make(User::class));
    }
263995
private function setUser2StepData()
    {
        $user = Auth::User();
        $twoStepAuth = $this->getTwoStepAuthStatus($user->id);
        $authCount = $twoStepAuth->authCount;
        $this->_user = $user;
        $this->_twoStepAuth = $twoStepAuth;
        $this->_authCount = $authCount;
        $this->_authStatus = $twoStepAuth->authStatus;
        $this->_remainingAttempts = config('laravel2step.laravel2stepExceededCount') - $authCount;
    }
836720
def user_attr(username, attribute):
    """"""
    return getattr(User.objects.get(username=username), attribute)
124772
def load(self, rawdata):
        
        if isinstance(rawdata, str):
            self.__parse_string(rawdata)
        else:
            # self.update() wouldn't call our custom __setitem__
            for key, value in rawdata.items():
                self[key] = value
        return
431541
def _set_data(self, action):
        
        if 'query' in action:
            self._set_query_data(action)
        elif action == 'imageinfo':
            self._set_imageinfo_data()
        elif action == 'parse':
            self._set_parse_data()
        elif action == 'random':
            self._set_random_data()
        elif action == 'labels':
            self._set_labels()
        elif action == 'wikidata':
            self._set_wikidata()
            self.get_labels()
        elif action == 'restbase':
            self._set_restbase_data()

        self._update_imageinfo()
        self._update_params()
991444
def setItemData(self, treeItem, column, value, role=Qt.EditRole):
        
        if role == Qt.CheckStateRole:
            if column != self.COL_VALUE:
                return False
            else:
                logger.debug("Setting check state (col={}): {!r}".format(column, value))
                treeItem.checkState = value
                return True

        elif role == Qt.EditRole:
            if column != self.COL_VALUE:
                return False
            else:
                logger.debug("Set Edit value (col={}): {!r}".format(column, value))
                treeItem.data = value
                return True
        else:
            raise ValueError("Unexpected edit role: {}".format(role))
981320
def setData(self, index, value, role=Qt.EditRole):
        """"""
        if not index.isValid() or self.readonly:
            return False
        i = index.row()
        j = index.column()
        value = from_qvariant(value, str)
        dtype = self._data.dtype.name
        if dtype == "bool":
            try:
                val = bool(float(value))
            except ValueError:
                val = value.lower() == "true"
        elif dtype.startswith("string") or dtype.startswith("bytes"):
            val = to_binary_string(value, 'utf8')
        elif dtype.startswith("unicode") or dtype.startswith("str"):
            val = to_text_string(value)
        else:
            if value.lower().startswith('e') or value.lower().endswith('e'):
                return False
            try:
                val = complex(value)
                if not val.imag:
                    val = val.real
            except ValueError as e:
                QMessageBox.critical(self.dialog, "Error",
                                     "Value error: %s" % str(e))
                return False
        try:
            self.test_array[0] = val  # will raise an Exception eventually
        except OverflowError as e:
            print("OverflowError: " + str(e))  # spyder: test-skip
            QMessageBox.critical(self.dialog, "Error",
                                 "Overflow error: %s" % str(e))
            return False

        # Add change to self.changes
        self.changes[(i, j)] = val
        self.dataChanged.emit(index, index)
        if not is_string(val):
            if val > self.vmax:
                self.vmax = val
            if val < self.vmin:
                self.vmin = val
        return True