} // Read public static uint Read(this NativeReader reader, uint offset, out NamedArgumentHandle handle) { uint value; offset = reader.DecodeUnsigned(offset, out value); handle = new NamedArgumentHandle((int)value); handle._Validate(); return offset; } // Read
} // Read public static uint Read(this NativeReader reader, uint offset, out NamedArgumentHandle[] values) { uint count; offset = reader.DecodeUnsigned(offset, out count); if (count == 0) { values = s_emptyNamedArgumentHandleArray; } else { values = new NamedArgumentHandle[count]; for (uint i = 0; i < count; ++i) { NamedArgumentHandle tmp; offset = reader.Read(offset, out tmp); values[i] = tmp; } } return offset; } // Read
} // IsNull internal bool IsNull(NamedArgumentHandle handle) { return (handle._value & 0x00FFFFFF) == 0; } // IsNull
} // ToHandle internal Handle ToHandle(NamedArgumentHandle handle) { return new Handle(handle._value); } // ToHandle
} // GetMethodTypeVariableSignature public NamedArgument GetNamedArgument(NamedArgumentHandle handle) { var record = new NamedArgument() { _reader = this, _handle = handle }; var offset = (uint)handle.Offset; offset = _streamReader.Read(offset, out record._flags); offset = _streamReader.Read(offset, out record._name); offset = _streamReader.Read(offset, out record._value); return record; } // GetNamedArgument
} // Equals public bool Equals(NamedArgumentHandle handle) { return _value == handle._value; } // Equals
} // Read public static uint Read(this NativeReader reader, uint offset, out NamedArgumentHandle[] values) { uint count; offset = reader.DecodeUnsigned(offset, out count); #if !NETFX_45 if (count == 0) { values = Array.Empty<NamedArgumentHandle>(); } else #endif { values = new NamedArgumentHandle[count]; for (uint i = 0; i < count; ++i) { NamedArgumentHandle tmp; offset = reader.Read(offset, out tmp); values[i] = tmp; } } return offset; } // Read