Package org.jruby
Class RubyString.FString
java.lang.Object
org.jruby.RubyBasicObject
org.jruby.RubyObject
org.jruby.RubyString
org.jruby.RubyString.FString
- All Implemented Interfaces:
Serializable
,CharSequence
,Cloneable
,Comparable<IRubyObject>
,Appendable
,InstanceVariables
,InternalVariables
,IRubyObject
,EncodingCapable
,MarshalEncoding
,CoreObjectType
,ByteListHolder
,CodeRangeable
- Enclosing class:
RubyString
An FString is a frozen string that is also deduplicated and cached. We add a field to hold one type of conversion
so it won't be performed repeatedly. Whatever type of conversion is requested first wins, since it will be very
rare for a String to be converted to a Symbol and a Fixnum and a Float.
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class org.jruby.RubyString
RubyString.EmptyByteListHolder, RubyString.FString
Nested classes/interfaces inherited from class org.jruby.RubyObject
RubyObject.Data
Nested classes/interfaces inherited from class org.jruby.RubyBasicObject
RubyBasicObject.Finalizer
-
Field Summary
Fields inherited from class org.jruby.RubyString
NULL_ARRAY, shareLevel
Fields inherited from class org.jruby.RubyObject
IVAR_INSPECTING_OBJECT_ALLOCATOR, OBJECT_ALLOCATOR, REIFYING_OBJECT_ALLOCATOR
Fields inherited from class org.jruby.RubyBasicObject
ALL_F, BASICOBJECT_ALLOCATOR, COMPARE_BY_IDENTITY_F, ERR_INSECURE_SET_INST_VAR, FALSE_F, FL_USHIFT, flags, FROZEN_F, IS_OVERLAID_F, metaClass, NEVER, NIL_F, REFINED_MODULE_F, STAMP_OFFSET, TAINTED_F, UNDEF, USER0_F, USER1_F, USER2_F, USER3_F, USER4_F, USER5_F, USER6_F, USER7_F, USER8_F, USER9_F, USERA_F, VAR_TABLE_OFFSET, varTable, varTableStamp
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondupAsFString
(Ruby runtime) protected void
intern()
to_f
(ThreadContext context) to_i
(ThreadContext context) Methods inherited from class org.jruby.RubyString
append, append, append, append_as_bytes, append_as_bytes, append_as_bytes, append19, appendAsDynamicString, appendAsStringOrAny, appendIntoString, ascii_only_p, asJavaString, associateEncoding, asString, b, byteindex, byteindex, byteListToString, byterindex, byterindex, bytes, bytesize, bytesize, byteslice, byteslice, bytesplice, bytesplice, bytesplice, bytesToString, bytesToString, capacity, capitalize, capitalize, capitalize, capitalize_bang, capitalize_bang, capitalize_bang, casecmp, casecmp_p, cat, cat, cat, cat, cat, cat, cat, cat, cat, cat19, cat19, catAscii, catString, catStringUnsafe, catWithCodeRange, catWithCodeRange, center, center, center, center, charAt, chars, checkEncoding, checkEncoding, checkEncoding, checkFrozen, checkStringType, chill, chill_symbol_string, chomp, chomp, chomp_bang, chomp_bang, chomp_bang19, chomp_bang19, chomp19, chomp19, chop, chop_bang, chr, clear, clear, clearCodeRange, codepoints, compareTo, concat, concat, concat, concatSingle, convertToString, count, count, count, createStringClass, crypt, decodeString, delete, delete, delete, delete_bang, delete_bang, delete_bang, delete_prefix, delete_prefix_bang, delete_suffix, delete_suffix_bang, doClone, downcase, downcase, downcase, downcase_bang, downcase_bang, downcase_bang, dump, dump, dup, dup, dupAsChilled, dupFrozen, each_byte, each_char, each_codepoint, each_grapheme_cluster, each_line, each_line, each_line, each_lineCommon, empty, empty_p, encode, encode, encode, encode, encode_bang, encode_bang, encode_bang, encode_bang, encode_bang, encodeBytelist, encoding, encStrScrub, encStrScrub, end_with_p, end_with_p, end_with_p, endsWithAsciiChar, endWith, ensureAvailable, ensureInstanceVariablesSettable, eql, equals, export, force_encoding, freeze, getbyte, getByteList, getBytes, getCodeRange, getEmptyByteList, getEncoding, getJavaClass, getMarshalEncoding, getNativeClassIndex, getUnicodeValue, getValue, grapheme_clusters, gsub, gsub, gsub_bang, gsub_bang, gsubFast, hash, hashCode, hasNul, hex, include_p, includeRange, independent, index, index, initialize, initialize, initialize, initialize_copy, initialize_copy, insert, inspect, inspect, inspect, inspect, intern, isAsciiOnly, isBare, isBare, isBrokenString, isChilled, isChilledLiteral, isCodeRangeAsciiOnly, isCodeRangeBroken, isCodeRangeValid, isEmpty, keepCodeRange, length, lines, lines, lines, ljust, ljust, ljust, ljust, lstrip, lstrip_bang, makeIndependent, makeIndependent, makeShared, makeShared, makeSharedString, match, match, match, match, match_p, match_p, match19, match19, match19, minus_at, modify, modify, modify19, modifyAndClearCodeRange, modifyAndKeepCodeRange, modifyCheck, modifyCheck, modifyExpand, mutateChilledString, newAllocatedString, newBinaryString, newBinaryString, newChilledString, newDebugChilledString, newDebugFrozenString, newEmptyBinaryString, newEmptyString, newEmptyString, newEmptyString, newEmptyString, newExternalStringWithEncoding, newFrozen, newFString, newInstance, newInternalFromJavaExternal, newString, newString, newString, newString, newString, newString, newString, newString, newString, newString, newString, newString, newString, newStringLight, newStringLight, newStringLight, newStringNoCopy, newStringNoCopy, newStringNoCopy, newStringNoCopy, newStringNoCopy, newStringNoCopy, newStringNoCopy, newStringShared, newStringShared, newStringShared, newStringShared, newStringShared, newStringShared, newStringShared, newStringShared, newStringShared, newStringShared, newUnicodeString, newUnicodeString, newUSASCIIString, newUsAsciiStringNoCopy, newUsAsciiStringShared, newUsAsciiStringShared, newUTF16String, newUTF16String, newUTF8String, newUTF8String, objAsString, oct, op_aref, op_aref, op_aset, op_aset, op_cmp, op_cmp, op_equal, op_format, op_ge, op_ge19, op_gt, op_gt19, op_le, op_le19, op_lt, op_lt19, op_match, op_mul, op_mul19, op_plus, op_plus19, ord, partition, partition, plus_at, plus_at, prepend, prepend, prepend, prepend, rbStrEscape, rbStrOffset, replace, replace, replace19, resize, reverse, reverse_bang, reverse_bang19, reverse19, rindex, rindex, rjust, rjust, rjust, rjust, rpartition, rstrip, rstrip_bang, rubyLength, scan, scanForCodeRange, scanForCodeRange, scrub, scrub, scrub_bang, scrub_bang, setbyte, setByteListShared, setCodeRange, setEncoding, setEncodingAndCodeRange, setReadLength, setValue, setValue, shouldMarshalEncoding, singletonClass, size, slice_bang, slice_bang, split, split, split, split, split, split, split, split, split, splitWithBlock, splitWithBlock, splitWithBlock, squeeze, squeeze, squeeze, squeeze_bang, squeeze_bang, squeeze_bang, start_with_p, start_with_p, start_with_p, startsWith, str_eql_p, str_eql_p19, strDup, strDup, strDup, strHashCode, stringToBytes, stringToInum, stringToInum, stringValue, strip, strip_bang, strLength, strScrub, sub, sub, sub_bang, sub_bang, subBangFast, subSequence, substr, substr, substr, substr19, substrEnc, substrEnc, succ, succ_bang, succ_bang, sum, sum, sumCommon, swapcase, swapcase, swapcase, swapcase_bang, swapcase_bang, swapcase_bang, to_c, to_f, to_i, to_i, to_i, to_r, to_s, toEncoding, toJava, toString, tr, tr_bang, tr_bang19, tr_s, tr_s_bang, tr_s_bang19, tr_s19, tr19, try_convert, undump, unmarshalFrom, unmarshalFrom, unpack, unpack, unpack, unpack1, unpack1, unseededStrHashCode, upcase, upcase, upcase, upcase_bang, upcase_bang, upcase_bang, upto, upto, valid_encoding_p, verifyAsciiCompatible, view
Methods inherited from class org.jruby.RubyObject
attachToObjectSpace, callInit, callInit, callInit, callInit, callInit, callInit, callInit, callInit, callInit, callInit, convertToType, dig, dig1, dig2, eqlInternal, equalInternal, finishObjectClass, inspect, op_eqq, puts, specificEval, toRubyString
Methods inherited from class org.jruby.RubyBasicObject
addFinalizer, addFinalizer, anyToString, callMethod, callMethod, callMethod, callMethod, callMethod, callMethod, callMethod, callMethod, callMethod, callSuper, checkArrayType, checkCallMethod, checkCallMethod, cloneSetup, convertToArray, convertToFloat, convertToHash, convertToInteger, convertToInteger, convertToInteger, copyInstanceVariablesInto, copySpecialInstanceVariables, dataGetStruct, dataGetStructChecked, dataWrapStruct, decode, display, dupFinalizer, dupSetup, eql_p, eql_p, equal_p, evalUnder, extend, fastGetInstanceVariable, fastGetInternalVariable, fastHasInstanceVariable, fastHasInternalVariable, fastSetInstanceVariable, fastSetInternalVariable, finishBasicObjectClass, forEachInstanceVariable, forEachInstanceVariableName, frozen_p, getCurrentContext, getFFIHandle, getFlag, getInstanceEvalClass, getInstanceEvalClass, getInstanceVariable, getInstanceVariableList, getInstanceVariableNameList, getInstanceVariables, getInternalVariable, getInternalVariables, getMarshalVariableList, getMetaClass, getMetaClass, getNativeHandle, getNativeTypeIndex, getObjectId, getRuntime, getSingletonClass, getSingletonClassClone, getSingletonClassCloneAndAttach, getSingletonClassCloneAndAttach, getType, getVariable, getVariableCount, getVariableList, getVariableNameList, hash, hashyInspect, hasInstanceVariable, hasInstanceVariables, hasInternalVariable, hasVariables, id, infectBy, inspectHashCode, instance_eval, instance_eval, instance_eval, instance_eval, instance_eval, instance_exec, instance_of_p, instance_variable_defined_p, instance_variable_get, instance_variable_set, instance_variables, isBuiltin, isClass, isFalse, isFrozen, isImmediate, isModule, isNil, isSpecialConst, isSpecialObject, isTaint, isTrue, isUntrusted, kind_of_p, makeMetaClass, makeMetaClass, makeMetaClassBootstrap, method, method, method, method_missing, methods, methods, nil_p, nonFixnumHashCode, nonFixnumHashCode, OBJ_INIT_COPY, objInitCopy, op_not, op_not_equal, op_not_match, private_methods, protected_methods, public_methods, rbClone, rbClone, rbInspect, remove_instance_variable, removeFinalizers, removeInstanceVariable, removeInternalVariable, respond_to_p, respond_to_p, respondsTo, respondsToMissing, respondsToMissing, send, send, send, send, send, setFFIHandle, setFlag, setFrozen, setInstanceVariable, setInternalVariable, setMetaClass, setNativeHandle, setTaint, setUntrusted, setVariable, singleton_method, singleton_method, singleton_method_added, singleton_method_removed, singleton_method_undefined, singleton_methods, specificEval, specificEval, specificEval, specificEval, syncVariables, syncVariables, taint, taint, tainted_p, testFrozen, testFrozen, to_a, to_a, to_s, trust, type, untaint, untrust, untrusted_p, validateInstanceVariable, validateInstanceVariable, validateInstanceVariable, variableTableContains, variableTableFastContains, variableTableFastFetch, variableTableFastStore, variableTableFetch, variableTableRemove, variableTableStore, variableTableSync, yieldUnder, yieldUnder
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.lang.CharSequence
chars, codePoints
Methods inherited from interface org.jruby.runtime.builtin.IRubyObject
checkStringType19, marshalLiveVariables
-
Constructor Details
-
FString
-
FString
-
-
Method Details
-
frozenCheck
protected void frozenCheck()- Overrides:
frozenCheck
in classRubyString
-
intern
- Overrides:
intern
in classRubyString
-
to_i
- Overrides:
to_i
in classRubyString
-
to_f
- Overrides:
to_f
in classRubyString
-
dupAsFString
- Overrides:
dupAsFString
in classRubyString
-