A_Map Bin
A_MapBin is a collection of keys and their associated values, which makes up some or part of a map.
Bins below a particular scale (LinearMapBinDescriptor.thresholdToHash) are usually represented via LinearMapBinDescriptor, which is primarily an arbitrarily ordered alternating sequence of keys and their associated values. The hashes of the keys are also stored for performance, among other things.
Above that threshold, a HashedMapBinDescriptor is used, which organizes the key-value pairs into a tree based on their hash values.
Author
Mark van Gulik
Inheritors
Properties
Dispatch to the descriptor.
Is the receiver an Avail byte string?
Is the receiver an Avail byte tuple?
Is the receiver an Avail extended integer?
Is the receiver an Avail function?
Answer whether this map bin is hashed (versus linear).
Dispatch to the descriptor.
Is the receiver an Avail IntTupleDescriptor? This is conservative, in that some object tuples may only contain ints but not be reported as being int tuples.
Is the receiver an Avail LongTupleDescriptor? This is conservative, in that some object tuples may only contain longs but not be reported as being long tuples.
Dispatch to the descriptor.
Is the receiver an Avail two-byte string?
Is the receiver an Avail unsigned byte?
Create an MapIterator that produces each Entry of the A_MapBin.
Answer a combined hash of all the keys in this map bin.
Answer the union of the kinds of each key in this bin. A value's exact type is always an instance type (an enumeration type of size 1), and the value's kind is the nearest supertype of that instance type that isn't itself an enumeration type.
Answer how many key/value pairs are in this map bin.
Answer a combined hash of all the values in this map bin.
Answer the union of the kinds of each value in this bin. A value's exact type is always an instance type (an enumeration type of size 1), and the value's kind is the nearest supertype of that instance type that isn't itself an enumeration type.
Extract the ObjectLayoutVariant from an object.
Functions
Turn the receiver into an indirection to the specified object.
Utility method for decomposing this object in the debugger.
Retrieve the object's {@linkplain AbstractDescriptor descriptor}.
Dispatcher helper function for routing messages to the descriptor.
Answer whether the receiver and the argument, both A_BasicObjects, are equal in value.
{@inheritDoc}
Answer whether the receiver, an object, and the argument, a byte string, are equal in value.
Answer whether the receiver, an object, and the argument, a byte tuple, are equal in value.
Answer whether the arguments, an object and a compiled code, are equal.
Answer whether the receiver equals the argument.
Answer whether the receiver equals the argument.
Determine whether the receiver is an enumeration with the given set of instances.
Answer whether the receiver, an object, and the argument, a fiber type, are equal in value.
Answer whether the receiver, an object, and the argument, a function type, are equal.
Answer whether the receiver equals the argument.
Answer whether this value equals the given list phrase type.
Answer whether the receiver equals the argument.
Dispatch to the descriptor.
Dispatch to the descriptor.
Dispatch to the descriptor.
Dispatch to the descriptor.
Dispatch to the descriptor.
Dispatch to the descriptor.
Dispatch to the descriptor.
Dispatch to the descriptor.
Answer whether the receiver equals the argument.
Extract a field from an object.
Extract a field from an object, using a one-based index into the field slots. This requires knowledge of the ObjectLayoutVariant, since the same field is at different indices in different variants.
Extract a field from an object, or answer null if it's not present.
Add or replace a field of an object.
Extract a field type from an object type.
Extract a field type from an object type, using the given field index, which is specific to an ObjectLayoutVariant.
Extract a field type from an object type, or null if it's not present.
Execute the given action with each key and associated value in this map bin.
Dispatch to the descriptor.
Answer the number of integer slots. All variable integer slots occur following the last fixed integer slot.
Dispatch to the descriptor.
Dispatch to the descriptor.
Dispatch to the descriptor.
The receiver is marked with an IMMUTABLE descriptor, but its subobjects have not yet been made immutable. Scan them now, and do any additional fix-ups necessary for the kind of object.
Dispatch to the descriptor.
The receiver is marked with a SHARED descriptor, but its subobjects have not yet been made shared. Scan them now, and do any additional fix-ups necessary for the kind of object.
Dispatch to the descriptor.
Dispatch to the descriptor.
Look up the key in this map bin. If not found, answer null. Use the provided hash of the key.
Create a map bin like the receiver, but with the given key associated with the given value. If canDestroy is true and the receiver is mutable, the receiver may be modified, and possibly act as the return value of this method.
Transform an element of this map bin. If there is an entry for the key, use the corresponding value as the second argument to the transformer, otherwise pass the notFoundValue. Write the result back to the bin, potentially recycling it if canDestroy is true.
Answer a map bin like the receiver, but with the given key excluded. If the key does not occur in the receiver, answer the same map bin, or an equivalent. If canDestroy is true and the receiver is mutable, the receiver can be modified and/or returned as the result.
Answer a name suitable for labeling a field containing this object.
Answer the number of object slots in this AvailObject. All variable object slots occur following the last fixed object slot.
Recursively print the receiver to the builder unless it is already present in the recursionMap. Printing will begin at the specified indent level, measured in horizontal tab characters.
Dispatch to the descriptor.
Answer whether the objects occupy the same memory addresses.
Dispatch to the descriptor.
Replace the object's {@linkplain AbstractDescriptor descriptor}.
Dispatch to the descriptor.
Replace my descriptor field with a FillerDescriptor. This blows up for most messages, catching incorrect (all, by definition) further accidental uses of this object.
Answer whether to show value-specific content in the file name for the debugger.
If the provided condition is true, synchronize with the receiver's monitor around the execution of the body function. Otherwise, run the body function without synchronization.
Follow indirections until a non-indirection is reached. Replace each indirection's target with the ultimate target.
Follow indirections until a non-indirection is reached. Replace each indirection's target with the ultimate target, even if it would cause the otherwise-forbidden immutable->mutable references. Only used during makeImmutable.
Follow indirections until a non-indirection is reached. Replace each indirection's target with the ultimate target, even if it would cause the otherwise-forbidden shared->unshared references. Only used during makeShared.
Answer the number of variable integer slots in this object. This does not include the fixed integer slots.
Answer the number of variable object slots in this AvailObject. This does not include the fixed object slots.