<!--
{
  "availability" : [
    "iOS: 16.0.0 -",
    "iPadOS: 16.0.0 -",
    "macCatalyst: 17.0.0 -",
    "macOS: 14.0.0 -",
    "tvOS: 16.0.0 -",
    "visionOS: 1.0.0 -",
    "watchOS: 9.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "MusicKit",
  "identifier" : "/documentation/MusicKit/MusicLibrarySectionedRequest/filterSections(matching:equalTo:)-7v8tr",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "MusicKit"
    ],
    "preciseIdentifier" : "s:8MusicKit0A23LibrarySectionedRequestV14filterSections8matching7equalToys7KeyPathCy0C6FilterAA0aC11RequestablePQzqd__G_qd__tAaJRzAA0aceM14ValueEquatableRd__lF"
  },
  "title" : "filterSections(matching:equalTo:)"
}
-->

# filterSections(matching:equalTo:)

Filters sections by a given property that matches a specific value.

```
mutating func filterSections<Value>(matching keyPath: KeyPath<SectionType.LibraryFilter, Value>, equalTo value: Value) where SectionType : MusicLibraryRequestable, Value : MusicLibraryRequestFilterValueEquatable
```

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)