Class MutableTruffleString.FromByteArrayNode
java.lang.Object
com.oracle.truffle.api.nodes.Node
com.oracle.truffle.api.strings.MutableTruffleString.FromByteArrayNode
- All Implemented Interfaces:
NodeInterface, Cloneable
- Enclosing class:
MutableTruffleString
Node to create a new
MutableTruffleString
from a byte array. See
execute(byte[], int, int, TruffleString.Encoding, boolean)
for details.- Since:
- 22.1
-
Nested Class Summary
Nested classes/interfaces inherited from class Node
Node.Child, Node.Children
-
Method Summary
Modifier and TypeMethodDescriptioncreate()
Create a newMutableTruffleString.FromByteArrayNode
.abstract MutableTruffleString
execute
(byte[] value, int byteOffset, int byteLength, TruffleString.Encoding encoding, boolean copy) Creates a newMutableTruffleString
from a byte array.Get the uncached version ofMutableTruffleString.FromByteArrayNode
.Methods inherited from class Node
accept, adoptChildren, atomic, atomic, copy, deepCopy, getChildren, getCost, getDebugProperties, getDescription, getEncapsulatingSourceSection, getLock, getParent, getRootNode, getSourceSection, insert, insert, isAdoptable, isSafelyReplaceableBy, notifyInserted, onReplace, replace, replace, reportPolymorphicSpecialize, reportReplace, toString
-
Method Details
-
execute
public abstract MutableTruffleString execute(byte[] value, int byteOffset, int byteLength, TruffleString.Encoding encoding, boolean copy) Creates a newMutableTruffleString
from a byte array. The array content is assumed to be encoded in the given encoding already. This operation allows non-copying string creation, i.e. the array parameter can be used directly by passingcopy = false
. If the array is modified after non-copying string creation, the string must be notified of this viaMutableTruffleString.notifyExternalMutation()
.- Since:
- 22.1
-
create
Create a newMutableTruffleString.FromByteArrayNode
.- Since:
- 22.1
-
getUncached
Get the uncached version ofMutableTruffleString.FromByteArrayNode
.- Since:
- 22.1
-