SymbolInstance.cs 493 B

12345678910111213141516171819202122
  1. using Jint.Native.Object;
  2. using Jint.Runtime;
  3. namespace Jint.Native.Symbol;
  4. internal sealed class SymbolInstance : ObjectInstance, IJsPrimitive
  5. {
  6. internal SymbolInstance(
  7. Engine engine,
  8. SymbolPrototype prototype,
  9. JsSymbol symbol) : base(engine)
  10. {
  11. _prototype = prototype;
  12. SymbolData = symbol;
  13. }
  14. Types IJsPrimitive.Type => Types.Symbol;
  15. JsValue IJsPrimitive.PrimitiveValue => SymbolData;
  16. public JsSymbol SymbolData { get; }
  17. }