Nullability (PsiExpression expression) { // expression.equals("string") -> expression == NOT_NULL if (ExpressionUtils.getCallForQualifier(expression) != null) { return Nullability.NOT_NULL; } // inferred nullability Nullability normal = NullabilityUtil.getExpressionNullability(expression, false); Nullability dataflow = NullabilityUtil.getExpressionNullability(expression, true); if (normal == Nullability.NOT_NULL || dataflow == Nullability.NOT_NULL) { return Nullability.NOT_NULL; } if (normal == Nullability.NULLABLE || dataflow == Nullability.NULLABLE) { return Nullability.NULLABLE; } return Nullability.UNKNOWN; }