Repository: flutter
Issue: [shared_preferences] document return values of remove and set... methods
Labels: d: api docs,p: shared_preferences,package,team-ecosystem,P2,triaged-ecosystem

### What package does this bug report belong to?

shared_preferences

### What target platforms are you seeing this bug on?

macOS

### Have you already upgraded your packages?

Yes

### Dependency versions

<details><summary>pubspec.lock</summary>

```lock
[Paste file content here]
```

</details>


### Steps to reproduce

read the API documentation https://pub.dev/documentation/shared_preferences/latest/shared_preferences/SharedPreferences-class.html

### Expected results

The remove and set... methods return `Future<bool>`. It should be documented what this return values actually mean. Does "true" represent successful operation? There is no hint in the API documentation. 

### Actual results

Missing documentation

### Code sample

<details open><summary>Code sample</summary>

```dart
var a = await prefs.setInt('counter', 10);
```

</details>


### Screenshots or Videos

<details open>
<summary>Screenshots / Video demonstration</summary>

[Upload media here]

</details>


### Logs

<details open><summary>Logs</summary>

```console
[Paste your logs here]
```

</details>


### Flutter Doctor output

<details open><summary>Doctor output</summary>

```console
 Flutter (Channel stable, 3.19.5, on macOS 14.4.1 23E224 darwin-x64, locale en-GB)
    • Flutter version 3.19.5 on channel stable at /Users/m/root/dev/flutter/flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 300451adae (5 days ago), 2024-03-27 21:54:07 -0500
    • Engine revision e76c956498
    • Dart version 3.3.3
    • DevTools version 2.31.1

[✓] Android toolchain - develop for Android devices (Android SDK version 33.0.2)
    • Android SDK at /Users/m/Library/Android/sdk
    • Platform android-34, build-tools 33.0.2
    • Java binary at: /Applications/Android Studio.app/Contents/jbr/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 17.0.9+0-17.0.9b1087.7-11185874)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 15.3)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Build 15E204a
    • CocoaPods version 1.15.2

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 2023.2)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 17.0.9+0-17.0.9b1087.7-11185874)

[✓] VS Code (version 1.87.2)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.84.0

[✓] Connected device (2 available)
    • macOS (desktop) • macos  • darwin-x64     • macOS 14.4.1 23E224 darwin-x64
    • Chrome (web)    • chrome • web-javascript • Google Chrome 123.0.6312.87

[✓] Network resources
    • All expected network resources are available.
```

</details>