Suggestion: mark SDK methods/fields which nullable

Former Member
Former Member
Would be a good idea to mark in SDK API documentation methods and variable with nullable (or notnull) annotations.
E.g:
//! The Sensor.Info class contains all information necessary for the Sensor. It can
//! be passed on the update or it can be retrieved on demand. The fields in this
//! class may return null so you should null check a value before using it.
//! @since 1.0.0
class Info {
//! Accelerometer reading for X, Y, and Z as an Array of Number values
//! (milli-g-units).
//! @nullable
//! @since 1.2.0
//! @return [Array]
var accel;

This info could later be used by eclipse (or my IDEA) plugin to show warning if the value is used without null check.


Unrelated question: do you mark doccomment annotation tags with @tag or (:tag)?