Skip to content

Commit

Permalink
Fix IDesignerSerializationManager nullability (#79429)
Browse files Browse the repository at this point in the history
* Add nullable annotation based off documentation
  • Loading branch information
elachlan authored Dec 14, 2022
1 parent f7f0e0a commit bcef34d
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2192,11 +2192,11 @@ public partial interface IDesignerSerializationManager : System.IServiceProvider
event System.ComponentModel.Design.Serialization.ResolveNameEventHandler ResolveName;
event System.EventHandler SerializationComplete;
void AddSerializationProvider(System.ComponentModel.Design.Serialization.IDesignerSerializationProvider provider);
object CreateInstance(System.Type type, System.Collections.ICollection arguments, string name, bool addToContainer);
object GetInstance(string name);
string GetName(object value);
object GetSerializer(System.Type objectType, System.Type serializerType);
System.Type GetType(string typeName);
object CreateInstance(System.Type type, System.Collections.ICollection? arguments, string? name, bool addToContainer);
object? GetInstance(string name);
string? GetName(object value);
object? GetSerializer(System.Type? objectType, System.Type serializerType);
System.Type? GetType(string typeName);
void RemoveSerializationProvider(System.ComponentModel.Design.Serialization.IDesignerSerializationProvider provider);
void ReportError(object errorInformation);
void SetName(object instance, string name);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,30 +71,30 @@ public interface IDesignerSerializationManager : IServiceProvider
/// of named instances. Objects that implement IComponent will be
/// added to the design time container if addToContainer is true.
/// </summary>
object CreateInstance(Type type, ICollection arguments, string name, bool addToContainer);
object CreateInstance(Type type, ICollection? arguments, string? name, bool addToContainer);

/// <summary>
/// Retrieves an instance of a created object of the given name, or
/// null if that object does not exist.
/// </summary>
object GetInstance(string name);
object? GetInstance(string name);

/// <summary>
/// Retrieves a name for the specified object, or null if the object
/// has no name.
/// </summary>
string GetName(object value);
string? GetName(object value);

/// <summary>
/// Retrieves a serializer of the requested type for the given
/// object type.
/// </summary>
object GetSerializer(Type objectType, Type serializerType);
object? GetSerializer(Type? objectType, Type serializerType);

/// <summary>
/// Retrieves a type of the given name.
/// </summary>
Type GetType(string typeName);
Type? GetType(string typeName);

/// <summary>
/// Removes a previously added serialization provider.
Expand Down

0 comments on commit bcef34d

Please sign in to comment.