dropbox / dropbox/dropbox-sdk-java

Use JSR 305 Nullable/Nonnull annotations?

Offen
#17 2 Kommentare 0 Reaktionen 0 zugewiesene Personen Beansprucht von @joshafeinberg Auf GitHub ansehen
dropbox enhancement
Vorherrschende Sprache
Java
Sterne
627
Forks
463
Ø Merge
5 Min.
Gemergte PRs (30 T.)
10

Beschreibung

Such annotations can help immensely when programming with the API, as it tells the API user what to expect.

Two examples from `DbxClient`:
- `.startGetFile()` can have null as its second argument; it will also never return null; therefore:

``` java
@Nonnull
DbxClient.Downloader startGetFile(String path, @Nullable String rev)
```
- `.getMetadata()` can return null:

``` java
@Nullable
DbxEntry getMetadata(String path)
```

Beitragsleitfaden

Für dieses Repository ist kein Beitragsleitfaden indexiert

Bewertung

Dieses Issue wurde noch nicht bewertet.

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.