Skip to content

Commit 6e9c1ea

Browse files
authored
Privatize ModelCommentReference.codeRef and .parsed (#3764)
1 parent d16bedc commit 6e9c1ea

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

lib/src/comment_references/model_comment_reference.dart

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -9,21 +9,21 @@ import 'package:dartdoc/src/comment_references/parser.dart';
99
/// A stripped down analyzer AST [CommentReference] containing only that
1010
/// information needed for Dartdoc.
1111
class ModelCommentReference {
12-
final String codeRef;
12+
final String _codeRef;
1313

1414
bool get hasCallableHint =>
15-
parsed.isNotEmpty &&
16-
((parsed.length > 1 && parsed.last.text == 'new') ||
17-
parsed.last is CallableHintEndNode);
15+
_parsed.isNotEmpty &&
16+
((_parsed.length > 1 && _parsed.last.text == 'new') ||
17+
_parsed.last is CallableHintEndNode);
1818

19-
List<String> get referenceBy => parsed
19+
List<String> get referenceBy => _parsed
2020
.whereType<IdentifierNode>()
2121
.map<String>((i) => i.text)
2222
.toList(growable: false);
2323

2424
/// Constructs a [ModelCommentReference] given a raw string.
25-
ModelCommentReference(this.codeRef);
25+
ModelCommentReference(this._codeRef);
2626

27-
late final List<CommentReferenceNode> parsed =
28-
CommentReferenceParser(codeRef).parse();
27+
late final List<CommentReferenceNode> _parsed =
28+
CommentReferenceParser(_codeRef).parse();
2929
}

0 commit comments

Comments
 (0)