diff --git a/src/Avalonia.Base/AvaloniaObject.cs b/src/Avalonia.Base/AvaloniaObject.cs
index f52638d948..160e6a3ca9 100644
--- a/src/Avalonia.Base/AvaloniaObject.cs
+++ b/src/Avalonia.Base/AvaloniaObject.cs
@@ -230,24 +230,6 @@ namespace Avalonia
return property.RouteGetValue(this);
}
- ///
- /// Gets a value.
- ///
- /// The type of the property.
- /// The property.
- /// The value.
- public T GetValue(AvaloniaProperty property)
- {
- property = property ?? throw new ArgumentNullException(nameof(property));
-
- return property switch
- {
- StyledPropertyBase styled => GetValue(styled),
- DirectPropertyBase direct => GetValue(direct),
- _ => throw new NotSupportedException("Unsupported AvaloniaProperty type.")
- };
- }
-
///
/// Gets a value.
///
@@ -323,33 +305,6 @@ namespace Avalonia
property.RouteSetValue(this, value, priority);
}
- ///
- /// Sets a value.
- ///
- /// The type of the property.
- /// The property.
- /// The value.
- /// The priority of the value.
- public void SetValue(
- AvaloniaProperty property,
- T value,
- BindingPriority priority = BindingPriority.LocalValue)
- {
- property = property ?? throw new ArgumentNullException(nameof(property));
-
- switch (property)
- {
- case StyledPropertyBase styled:
- SetValue(styled, value, priority);
- break;
- case DirectPropertyBase direct:
- SetValue(direct, value);
- break;
- default:
- throw new NotSupportedException("Unsupported AvaloniaProperty type.");
- }
- }
-
///
/// Sets a value.
///