Set the element $index in the list.

@param int   $index    The index of the element
@param mixed $value    The value to set
@param bool  $in_place Whether to modify the current list
352117
public function set($index, $value, $in_place = false)
    {
        if (!is_int($index) || $index < 0) {
            throw new \InvalidArgumentException('ItemList::set() expects a positive integer argument.');
        }

        if ($in_place) {
            $this->list[$index] = $value;

            return $this;
        }

        $modified = $this->list;
        $modified[$index] = $value;

        return new ItemList($modified);
    }
321823
public void setValueAt( int index, double value ) {

        int row = index / data[0].length;
        int col = index % data[0].length;

        data[row][col] = value;
    }
1265554
public void setFloat(int index, float value)
    {
        checkIndexLength(index, SizeOf.SIZE_OF_FLOAT);
        unsafe.putFloat(base, address + index, value);
    }
850051
public static Object setOrAppend(Object array, int index, Object value) {
		if(index < length(array)) {
			Array.set(array, index, value);
			return array;
		}else {
			return append(array, value);
		}
	}
282597
public function setIndexKey($value = null)
    {
        if ($value !== null && ! $value instanceof \Protobuf\Stream) {
            $value = \Protobuf\Stream::wrap($value);
        }

        $this->IndexKey = $value;
    }
614579
private function _set($index, $value, $accept_reverse_index) : array
    {
        $values = $this->getValues();
        if ($accept_reverse_index){
            $index = $this->_rindex($index, $values);
        }
        $values[$index] = $value;
        return $values;
    }
639815
public function offsetSet($offset, $value)
    {
        dd($value);
        if(is_null($offset)) {
            $this->{$this->index} = $value;
            $this->index++;
        } else {
            $this->$offset = $value;
        }
    }
1079138
public void setValueAtIn(Object value, int index, List aList) {
        Object cleanValue = cleanupValue(value);
        while (aList.size() <= index) {
            aList.add(null);
        }
        aList.set(index, cleanValue);
    }
59055
public function set($index, $value): Utility
    {
        $newBag = $this->toArray();

        $newBag[$index] = $value;

        return new self($newBag);
    }
307509
public function set($index, $value)
    {
        if($index >= $this->count())
            throw new OutOfRangeException('Index out of range');

        $this->_collection[$index] = $value;
    }
545923
public function set($index, $element)
    {
        if (null === $index) {
            $this->collections[] = $element;
        } else {
            $this->collections[$index] = $element;
        }

        return $this;
    }
366545
public function set(int $index, $value): bool {
        if ($index < 0 || $index > $this->size()) {
            throw new IndexOutOfBoundsException();
        }
        $this->array[$index] = $value;
        return true;
    }
795585
public function update(int $index, $value): bool
    {
        return $this->handle->lSet($this->name, $index, $value);
    }
1223568
public function setSession(string $index = '', $value = '')
    {
        if (array_key_exists($index, $_SESSION))
        {
            return false;
        }

        $_SESSION[$index] = $value;

        return true;
    }
25236
public int setInt(
        @DoNotSub final int index,
        final int element)
    {
        checkIndex(index);

        final int previous = elements[index];
        elements[index] = element;

        return previous;
    }
1298430
public void setText(int index, String value)
   {
      set(selectField(ResourceFieldLists.CUSTOM_TEXT, index), value);
   }
730963
public function remove($index, $in_place = false)
    {
        if (!is_int($index) || $index < 0) {
            throw new \InvalidArgumentException('ItemList::remove() expects a positive integer argument.');
        }

        if ($in_place) {
            unset($this->list[$index]);

            return $this;
        }

        $modified = $this->list;
        unset($modified[$index]);

        return new ItemList($modified);
    }