Implemented interface member:
method
GetFormats
System.Windows.Forms.IDataObject.GetFormats(System.Boolean)
13 references to GetFormats
System.Windows.Forms (1)
System\Windows\Forms\OLE\DataObject.cs (1)
111public virtual string[] GetFormats() => GetFormats(autoConvert: true);
System.Windows.Forms.Tests (12)
System\Windows\Forms\DataObjectTests.cs (12)
572.Setup(o => o.GetFormats(true)) 576mockDataObject.Verify(o => o.GetFormats(true), Times.Once()); 606dataObject.GetFormats(autoConvert).Should().BeEmpty(); 614dataObject.GetFormats(autoConvert: true).Should().Equal(["format1"]); 615dataObject.GetFormats(autoConvert: false).Should().Equal(["format1"]); 618dataObject.GetFormats(autoConvert: true).Should().Equal(["format1", "UnicodeText"]); 619dataObject.GetFormats(autoConvert: false).Should().Equal(["format1", "UnicodeText"]); 623dataObject.GetFormats(autoConvert: true).OrderBy(s => s).Should().Equal(["format1", "format2", "UnicodeText"]); 624dataObject.GetFormats(autoConvert: false).OrderBy(s => s).Should().Equal(["format1", "format2", "UnicodeText"]); 628dataObject.GetFormats(autoConvert: true).OrderBy(s => s).Should().Equal(["Bitmap", "format1", "format2", "System.Drawing.Bitmap", "UnicodeText", "WindowsForms10PersistentObject"]); 629dataObject.GetFormats(autoConvert: false).OrderBy(s => s).Should().Equal(["format1", "format2", "System.Drawing.Bitmap", "UnicodeText", "WindowsForms10PersistentObject"]); 652dataObject.GetFormats(autoConvert).Should().BeSameAs(result);