Package org.jruby
Class RubyGlobal.StringOnlyRubyHash
java.lang.Object
org.jruby.RubyBasicObject
org.jruby.RubyObject
org.jruby.RubyHash
org.jruby.RubyGlobal.StringOnlyRubyHash
- All Implemented Interfaces:
Serializable,Cloneable,Comparable<IRubyObject>,Map,InstanceVariables,InternalVariables,IRubyObject,CoreObjectType
- Direct Known Subclasses:
RubyGlobal.CaseInsensitiveStringOnlyRubyHash,RubyGlobal.ReadOnlySystemPropertiesHash
- Enclosing class:
- RubyGlobal
A Pseudo-hash whose keys and values are required to be Strings.
On all platforms, the keys are case-sensitive.
Used for ENV_JAVA.
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class org.jruby.RubyHash
RubyHash.RubyHashEntry, RubyHash.Visitor, RubyHash.VisitorWithState<T>Nested classes/interfaces inherited from class org.jruby.RubyObject
RubyObject.DataNested classes/interfaces inherited from class org.jruby.RubyBasicObject
RubyBasicObject.Finalizer -
Field Summary
FieldsFields inherited from class org.jruby.RubyHash
COMPARE_BY_IDENTITY_F, DEFAULT_INSPECT_STR_SIZE, KEYWORD_REST_ARGUMENTS_F, MRI_PRIMES, NO_ENTRY, SetValueVisitor, size, StoreValueVisitorFields inherited from class org.jruby.RubyObject
IVAR_INSPECTING_OBJECT_ALLOCATOR, OBJECT_ALLOCATOR, REIFYING_OBJECT_ALLOCATORFields inherited from class org.jruby.RubyBasicObject
ALL_F, BASICOBJECT_ALLOCATOR, 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, UNTRUST_F, 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, varTableStampFields inherited from interface org.jruby.runtime.builtin.IRubyObject
NULL_ARRAY -
Constructor Summary
ConstructorsConstructorDescriptionStringOnlyRubyHash(Ruby runtime, Map<RubyString, RubyString> valueMap, IRubyObject defaultValue) StringOnlyRubyHash(Ruby runtime, Map<RubyString, RubyString> valueMap, IRubyObject defaultValue, boolean updateRealENV) -
Method Summary
Modifier and TypeMethodDescriptionprivate IRubyObjectcase_aware_op_aset(ThreadContext context, IRubyObject key, IRubyObject value) private static booleanequalIgnoreCase(ThreadContext context, RubyString str1, RubyString str2) protected RubyStringgetCorrectKey(RubyString key) protected IRubyObjectinternalGet(IRubyObject key) protected booleanprivate static booleanisPATH(ThreadContext context, RubyString name) protected static booleanisStringLike(IRubyObject obj) protected static IRubyObjectnewName(ThreadContext context, IRubyObject key, IRubyObject valueArg) protected static IRubyObjectnewString(ThreadContext context, RubyString value) protected static IRubyObjectnewString(ThreadContext context, RubyString value, org.jcodings.Encoding encoding) protected static IRubyObjectnewString(ThreadContext context, IRubyObject obj) op_aset(ThreadContext context, IRubyObject key, IRubyObject value) rb_hash_asetop_aset19(ThreadContext context, IRubyObject key, IRubyObject value) Deprecated.to_hash(ThreadContext context) rb_hash_to_hashprotected static IRubyObjectverifyStringLike(ThreadContext context, IRubyObject test) private static RubyStringverifyValidKey(ThreadContext context, RubyString key, IRubyObject value) Methods inherited from class org.jruby.RubyHash
allSymbols, any_p, aref, aset, assoc, checkIterating, clear, compact, compact_bang, compare, compare_by_identity, compare_by_identity_p, containsKey, containsValue, convertToHash, create, createHashClass, default_proc, default_proc, default_value_get, default_value_get, default_value_get, default_value_set, default_value_set, delete, delete, delete_if, delete_ifInternal, dig, dig, dig, dig, directEntrySet, directKeySet, directValues, dup, dupFast, each, each_key, each_keyCommon, each_pair, each_pairCommon, each_pairCommon, each_value, each_valueCommon, each19, eachCommon, empty_p, empty_p, entrySet, equals, fastARef, fastASet, fastASet, fastASetCheckString, fastASetCheckString19, fastASetSmall, fastASetSmall, fastASetSmallCheckString, fastASetSmallCheckString19, fastDelete, fetch, fetch, fetch, fetch_values, flatten, flatten, get, getEntry, getIfNone, getJavaClass, getNativeClassIndex, has_key_p, has_key_p, has_value_p, hasDefaultProc, hash, hash, hash19, hashValue, index, index19, initialize, initialize_copy, initialize_copy19, inspect, inspect, inspect19, inspectHash, internalDelete, internalDeleteEntry, internalGetEntry, internalJavaPut, internalPut, internalPutIfNoKey, internalPutNoResize, internalPutSmall, invert, isComparedByIdentity, isEmpty, isKeywordRestArguments, keep_if, keep_ifCommon, key, keys, keys, keySet, marshalTo, merge, merge, merge_bang, merge_bang, merge_bang19, modify, newHash, newHash, newHash, newKwargs, newSmallHash, op_aref, op_aset, op_asetForString, op_asetSmallForString, op_eql, op_eql19, op_equal, op_ge, op_gt, op_le, op_lt, put, putAll, rassoc, rb_clear, rb_clear, rb_size, rb_size, rb_values, rb_values, rbClone, rehash, rehash, reject, reject_bang, reject_bangInternal, rejectInternal, remove, replace, replace19, select, select_bang, select19, set_default_proc, set_default_proc, set_default_proc20, setComparedByIdentity, setKeywordRestArguments, shift, size, slice, sort, to_a, to_a, to_h, to_h, to_h_block, to_hash, to_proc, to_s, to_s19, transform_keys, transform_keys_bang, transform_values, transform_values_bang, try_convert, unmarshalFrom, values, values, values_at, visitAll, visitAllMethods inherited from class org.jruby.RubyObject
attachToObjectSpace, callInit, callInit, callInit, callInit, callInit, callInit, callInit, callInit, callInit, callInit, convertToType, createObjectClass, dig, dig1, dig2, eqlInternal, equalInternal, hashCode, inspect, op_eqq, puts, specificEval, toRubyString, toStringMethods inherited from class org.jruby.RubyBasicObject
addFinalizer, anyToString, asJavaString, asString, callMethod, callMethod, callMethod, callMethod, callMethod, callMethod, callMethod, callMethod, callMethod, callSuper, checkArrayType, checkCallMethod, checkCallMethod, checkFrozen, checkStringType, checkStringType19, compareTo, convertToArray, convertToFloat, convertToInteger, convertToInteger, convertToInteger, convertToString, copyInstanceVariablesInto, copySpecialInstanceVariables, createBasicObjectClass, dataGetStruct, dataGetStructChecked, dataWrapStruct, decode, defaultToJava, display, dup, ensureInstanceVariablesSettable, eql, eql_p, equal_p, equal_p19, evalUnder, extend, fastGetInstanceVariable, fastGetInternalVariable, fastHasInstanceVariable, fastHasInternalVariable, fastSetInstanceVariable, fastSetInternalVariable, freeze, frozen_p, getFFIHandle, getFlag, getInstanceEvalClass, getInstanceVariable, getInstanceVariableList, getInstanceVariableNameList, getInstanceVariables, getInternalVariable, getInternalVariables, getMetaClass, getMetaClass, getNativeHandle, getNativeTypeIndex, getObjectId, getRuntime, getSingletonClass, getSingletonClassClone, getSingletonClassCloneAndAttach, getType, getVariable, getVariableCount, getVariableList, getVariableNameList, hashyInspect, hasInstanceVariable, hasInstanceVariables, hasInternalVariable, hasVariables, id, infectBy, infectBy, infectBy, initialize, initialize_copy, initialize19, inspectHashCode, instance_eval, instance_eval, instance_eval, instance_eval, instance_eval19, instance_eval19, instance_eval19, instance_eval19, instance_exec, instance_exec19, instance_of_p, instance_variable_defined_p, instance_variable_get, instance_variable_set, instance_variables, instance_variables19, isBuiltin, isClass, isFalse, isFrozen, isImmediate, isModule, isNil, isSpecialConst, isSpecialObject, isTaint, isTrue, isUntrusted, kind_of_p, makeMetaClass, method, method_missing, method_missing19, method19, methods, methods, methods19, methodsImpl, nil_p, nonFixnumHashCode, OBJ_INIT_COPY, objInitCopy, op_cmp, op_equal_19, op_match, op_match19, op_not, op_not_equal, op_not_match, private_methods, private_methods19, protected_methods, protected_methods19, public_methods, public_methods19, rbClone, rbClone, rbInspect, recacheBuiltinMethods, remove_instance_variable, removeFinalizers, removeInstanceVariable, removeInternalVariable, respond_to_p, respond_to_p, respond_to_p, respond_to_p19, respond_to_p19, respondsTo, respondsToMissing, respondsToMissing, send, send, send, send, send, send19, send19, send19, send19, setFFIHandle, setFlag, setFrozen, setInstanceVariable, setInternalVariable, setMetaClass, setNativeHandle, setTaint, setUntrusted, setVariable, singleton_method, singleton_method_added, singleton_method_added19, singleton_method_removed, singleton_method_removed19, singleton_method_undefined, singleton_method_undefined19, singleton_methods, specificEval, specificEval, specificEval, specificEval, syncVariables, syncVariables, taint, taint, tainted, tainted_p, testFrozen, testFrozen, to_s, toJava, trust, type, type_deprecated, untaint, untrust, untrusted_p, validateInstanceVariable, validateInstanceVariable, validateInstanceVariable, variableTableContains, variableTableFastContains, variableTableFastFetch, variableTableFastStore, variableTableFetch, variableTableRemove, variableTableStore, variableTableSync, yieldUnder, yieldUnderMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface java.util.Map
compute, computeIfAbsent, computeIfPresent, forEach, getOrDefault, hashCode, merge, putIfAbsent, remove, replace, replace, replaceAll
-
Field Details
-
updateRealENV
private final boolean updateRealENV -
PATH_BYTES
-
-
Constructor Details
-
StringOnlyRubyHash
public StringOnlyRubyHash(Ruby runtime, Map<RubyString, RubyString> valueMap, IRubyObject defaultValue, boolean updateRealENV) -
StringOnlyRubyHash
public StringOnlyRubyHash(Ruby runtime, Map<RubyString, RubyString> valueMap, IRubyObject defaultValue)
-
-
Method Details
-
isCaseSensitive
protected boolean isCaseSensitive() -
to_hash
Description copied from class:RubyHashrb_hash_to_hash -
internalGet
- Overrides:
internalGetin classRubyHash
-
op_aset
Description copied from class:RubyHashrb_hash_aset -
op_aset19
Deprecated. -
case_aware_op_aset
-
verifyStringLike
-
verifyValidKey
-
isStringLike
-
getCorrectKey
-
newName
-
newString
protected static IRubyObject newString(ThreadContext context, RubyString value, org.jcodings.Encoding encoding) -
newString
-
newString
-
isPATH
-
equalIgnoreCase
-