Microsoft.VisualStudio.Project.SettingsPage.GetTypedProperty C# (CSharp) Method

GetTypedProperty() public method

public GetTypedProperty ( string name, Type type, _PersistStorageType storageType ) : object
name string
type System.Type
storageType _PersistStorageType
return object
        public virtual object GetTypedProperty(string name, Type type, _PersistStorageType storageType)
        {
            string value = GetProperty(name, storageType);
            if(string.IsNullOrEmpty(value)) return null;

            TypeConverter tc = TypeDescriptor.GetConverter(type);
            return tc.ConvertFromInvariantString(value);
        }