Ejemplo n.º 1
0
interface mixin MixinCanNotIncludeSetlike {
  readonly setlike<DOMString>;
};

"""
    #    idl = idl.replace(' ', '  ')
    print("IDL >>>\n" + idl + "\n<<<")
    parser.parse(idl)
    print(repr(parser))

    test_difference(idl, unicode(parser))
    assert (unicode(parser) == idl)

    print("MARKED UP:")
    marker = NullMarker()
    test_difference(idl, parser.markup(marker))
    assert (marker.text == idl)
    print(parser.markup(Marker()))

    print("Complexity: " + unicode(parser.complexityFactor))

    for construct in parser.constructs:
        print(
            unicode(construct.idlType) + u': ' + unicode(construct.normalName))
        for member in construct:
            print('    ' + member.idlType + ': ' + unicode(member.normalName) +
                  ' (' + unicode(member.name) + ')')

    print("FIND:")
    print(parser.find('round').fullName)
    print(parser.find('Foo/method/y').fullName)
Ejemplo n.º 2
0
  long methodWithOptionalDict(long one, MyDictionary optionalDict, optional long three);    // should error
  long methodWithRequiredDict(long one, FooDict requiredDict);
  long methodWithRequiredDict(long one, FooDict requiredDict, long three);
};
"""
    #    idl = idl.replace(' ', '  ')
    print "IDL >>>\n" + idl + "\n<<<"
    parser.parse(idl)
    print repr(parser)

    testDifference(idl, unicode(parser))
    assert (unicode(parser) == idl)

    print "MARKED UP:"
    marker = NullMarker()
    testDifference(idl, parser.markup(marker))
    assert (marker.text == idl)
    print parser.markup(Marker())

    print "Complexity: " + unicode(parser.complexityFactor)

    for construct in parser.constructs:
        print unicode(construct.idlType) + u': ' + unicode(
            construct.normalName)
        for member in construct:
            print '    ' + member.idlType + ': ' + unicode(
                member.normalName) + ' (' + unicode(member.name) + ')'

    print "FIND:"
    print parser.find('round').fullName
    print parser.find('Foo/method/y').fullName
Ejemplo n.º 3
0
interface mixin MixinCanNotIncludeSetlike {
  readonly setlike<DOMString>;
};

"""
#    idl = idl.replace(' ', '  ')
    print("IDL >>>\n" + idl + "\n<<<")
    parser.parse(idl)
    print(repr(parser))

    test_difference(idl, unicode(parser))
    assert(unicode(parser) == idl)

    print("MARKED UP:")
    marker = NullMarker()
    test_difference(idl, parser.markup(marker))
    assert(marker.text == idl)
    print(parser.markup(Marker()))

    print("Complexity: " + unicode(parser.complexityFactor))


    for construct in parser.constructs:
        print(unicode(construct.idlType) + u': ' + unicode(construct.normalName))
        for member in construct:
            print('    ' + member.idlType + ': ' + unicode(member.normalName) + ' (' + unicode(member.name) + ')')

    print("FIND:")
    print(parser.find('round').fullName)
    print(parser.find('Foo/method/y').fullName)
    print(parser.find('Foo.method').fullName)
Ejemplo n.º 4
0
    any[] value = null;
    any [] value = null;
};

"""
#    idl = idl.replace(' ', '  ')
    print "IDL >>>\n" + idl + "\n<<<"
    parser.parse(idl)
    print repr(parser)

    testDifference(idl, unicode(parser))
    assert(unicode(parser) == idl)

    print "MARKED UP:"
    marker = NullMarker()
    testDifference(idl, parser.markup(marker))
    assert(marker.text == idl)
    print parser.markup(Marker())

    print "Complexity: " + unicode(parser.complexityFactor)
    
    
    for construct in parser.constructs:
        print unicode(construct.idlType) + u': ' + unicode(construct.normalName)
        for member in construct:
            print '    ' + member.idlType + ': ' + unicode(member.normalName) + ' (' + unicode(member.name) + ')'

    print "FIND:"
    print parser.find('round').fullName
    print parser.find('Foo/method/y').fullName
    print parser.find('Foo.method').fullName