public override void BuildIDLInto(IDLFormatter ih) { EnterElement(); ih.AppendLine("["); var lprops = _data.Attributes; for (var i = 0; i < lprops.Count; ++i) { ih.AppendLine(" " + lprops[i] + (i < (lprops.Count - 1) ? "," : "")); } ih.AppendLine("]"); ih.AppendLine(_data.Name + " {"); //if (_ta.cFuncs > 0 || _ta.cVars > 0) //{ // Naughty, but rely on side effect of verifying children. using (new IDLHelperTab(ih)) { _propChildren.BuildIDLInto(ih); _methodChildren.BuildIDLInto(ih); } //} ih.AppendLine("};"); ExitElement(); }
public override void BuildIDLInto(IDLFormatter ih) { ih.AppendLine("["); var lprops = new List <string> { "uuid(" + _ta.guid + ")" }; var help = _ti.GetHelpDocumentationById(-1, out var context); AddHelpStringAndContext(lprops, help, context); if (0 != (_ta.wTypeFlags & TypeAttr.TypeFlags.TYPEFLAG_FHIDDEN)) { lprops.Add("hidden"); } if (0 != (_ta.wTypeFlags & TypeAttr.TypeFlags.TYPEFLAG_FDUAL)) { lprops.Add("dual"); } if (0 != (_ta.wTypeFlags & TypeAttr.TypeFlags.TYPEFLAG_FRESTRICTED)) { lprops.Add("restricted"); } if (0 != (_ta.wTypeFlags & TypeAttr.TypeFlags.TYPEFLAG_FNONEXTENSIBLE)) { lprops.Add("nonextensible"); } if (0 != (_ta.wTypeFlags & TypeAttr.TypeFlags.TYPEFLAG_FOLEAUTOMATION)) { lprops.Add("oleautomation"); } for (var i = 0; i < lprops.Count; ++i) { ih.AppendLine(" " + lprops[i] + (i < (lprops.Count - 1) ? "," : "")); } ih.AppendLine("]"); ih.AppendLine("dispinterface " + _name + " {"); if (_ta.cFuncs > 0 || _ta.cVars > 0) { // Naughty, but rely on side effect of verifying children. using (new IDLHelperTab(ih)) { _propChildren?.BuildIDLInto(ih); _methodChildren?.BuildIDLInto(ih); } } ih.AppendLine("};"); }