chromium/third_party/blink/renderer/core/testing/record_test.idl

// Copyright 2017 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

typedef record<DOMString, long> RecordTypedef;

interface RecordTest {
    void setStringLongRecord(RecordTypedef arg);
    RecordTypedef getStringLongRecord();

    void setNullableStringLongRecord(RecordTypedef? arg);
    RecordTypedef? getNullableStringLongRecord();

    void setByteStringByteStringRecord(record<ByteString, ByteString> arg);

    void setStringElementRecord(record<DOMString, Element> arg);
    record<DOMString, Element> getStringElementRecord();

    void setUSVStringUSVStringBooleanRecordRecord(record<USVString, record<USVString, boolean>> arg);
    record<USVString, record<USVString, boolean>> getUSVStringUSVStringBooleanRecordRecord();

    record<DOMString, sequence<ByteString>> returnStringByteStringSequenceRecord();

    boolean unionReceivedARecord((boolean or record<ByteString, ByteString>) arg);

    // Test the bindings generator code: unions and dictionaries must trace a
    // record when it's represented as a HeapVector.
    void setFloatOrStringElementRecord((float or record<DOMString, Element>) arg);
};