Skip to content

Latest commit

 

History

History
27 lines (21 loc) · 506 Bytes

change_at.md

File metadata and controls

27 lines (21 loc) · 506 Bytes
layout api-command
language Java
permalink api/java/change_at/
command changeAt
related_commands
insertAt spliceAt deleteAt
insert_at/
splice_at/
delete_at/

Command syntax

{% apibody %} array.changeAt(offset, value) → array {% endapibody %}

Description

Change a value in an array at a given index. Returns the modified array.

Example: Bruce Banner hulks out.

r.expr(r.array("Iron Man", "Bruce", "Spider-Man")).changeAt(1, "Hulk")
 .run(conn);