Class MutableTruffleString.AsManagedNode
java.lang.Object
com.oracle.truffle.api.nodes.Node
com.oracle.truffle.api.strings.MutableTruffleString.AsManagedNode
- All Implemented Interfaces:
NodeInterface, Cloneable
- Enclosing class:
MutableTruffleString
Node to get the given
AbstractTruffleString
as a managed
MutableTruffleString
, meaning that the resulting string's backing memory is not a
native pointer. See execute(AbstractTruffleString, TruffleString.Encoding)
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.AsManagedNode
.abstract MutableTruffleString
execute
(AbstractTruffleString a, TruffleString.Encoding expectedEncoding) If the given string is already a managed (i.e.Get the uncached version ofMutableTruffleString.AsManagedNode
.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(AbstractTruffleString a, TruffleString.Encoding expectedEncoding) If the given string is already a managed (i.e. not backed by a native pointer) string, return it. Otherwise, copy the string's native pointer content into a Java byte array and return a new string backed by the byte array.- Since:
- 22.1
-
create
Create a newMutableTruffleString.AsManagedNode
.- Since:
- 22.1
-
getUncached
Get the uncached version ofMutableTruffleString.AsManagedNode
.- Since:
- 22.1
-