2 implementations of GetInstance
System.Windows.Forms.Design (2)
System\ComponentModel\Design\Serialization\CodeDomComponentSerializationService.CodeDomSerializationStore.PassThroughSerializationManager.cs (1)
61object? IDesignerSerializationManager.GetInstance(string name)
System\ComponentModel\Design\Serialization\DesignerSerializationManager.cs (1)
793object? IDesignerSerializationManager.GetInstance(string name)
31 references to GetInstance
System.Windows.Forms.Design (16)
System\ComponentModel\Design\Serialization\CodeDomComponentSerializationService.CodeDomSerializationStore.ComponentListCodeDomSerializer.cs (8)
130e.Value = manager.GetInstance(name); 147object? comp = manager.GetInstance(name); 179object? comp = manager.GetInstance(name); 215IComponent? curComp = manager.GetInstance(outerComponent) as IComponent; 368if (exValue is not null && !resolved && canInvokeManager && manager.GetInstance(name) is null) 383resolved = manager.GetInstance(name) is not null; 415object? comp = manager.GetInstance(name); 440object? comp = manager.GetInstance(name);
System\ComponentModel\Design\Serialization\CodeDomComponentSerializationService.CodeDomSerializationStore.cs (2)
250if (instance is not null && dsm.GetInstance(compName) is null) 263object? instance = ((IDesignerSerializationManager)delegator.Manager).GetInstance(name);
System\ComponentModel\Design\Serialization\CodeDomComponentSerializationService.CodeDomSerializationStore.PassThroughSerializationManager.cs (1)
63object? instance = ((IDesignerSerializationManager)Manager).GetInstance(name);
System\ComponentModel\Design\Serialization\CodeDomSerializerBase.cs (5)
772result = manager.GetInstance(argumentReferenceEx.ParameterName); 789object? namedObject = manager.GetInstance(fieldReferenceEx.FieldName); 921result = manager.GetInstance(variableReferenceEx.VariableName); 1698object? baseInstance = manager.GetInstance(nameParts[0]); 2085while (manager.GetInstance(name) is not null || (cache is not null && cache.ContainsLocalName(name)));
System.Windows.Forms.Design.Tests (15)
System\ComponentModel\Design\Serialization\DesignerSerializationManagerTests.cs (15)
754Assert.Same(expected, iManager.GetInstance(name)); 757Assert.Same(expected, iManager.GetInstance(name)); 770Assert.Same(instance, iManager.GetInstance(name)); 773Assert.Same(instance, iManager.GetInstance(name)); 788Assert.Null(iManager.GetInstance(name)); 791Assert.Null(iManager.GetInstance(name)); 830Assert.Same(value, iManager.GetInstance(name)); 834Assert.Same(value, iManager.GetInstance(name)); 839Assert.Same(component, iManager.GetInstance("name")); 845Assert.Same(component, iManager.GetInstance("name")); 850Assert.Null(iManager.GetInstance(name)); 859Assert.Throws<ArgumentNullException>("name", () => iManager.GetInstance(null)); 868Assert.Throws<InvalidOperationException>(() => iManager.GetInstance(name)); 1920Assert.Same(instance1, iManager.GetInstance(name)); 1925Assert.Same(instance2, iManager.GetInstance("OtherName"));