From b0f60552eabede5d698cb95fba2b17dbceb6e734 Mon Sep 17 00:00:00 2001 From: Jason Franklin Date: Sat, 10 Jun 2017 09:57:18 -0400 Subject: [PATCH] Rewrite and expand the header in bookmark.vim The header in "bookmark.vim" was pretty weak. It provided no description of the class it contains and no direction for the reader. In particular it did not note the dual purpose of the "Bookmark" class. The fact that the "Bookmark" class serves two purposes must be noted because many readers will expect class definitions to obey the single responsibility principle! If there is a chance for a major refactor of this class in the future, a priority would be splitting the class in two so that a "BookmarkList" class can assume the responsibility for providing a container for all "Bookmark" objects. --- lib/nerdtree/bookmark.vim | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/lib/nerdtree/bookmark.vim b/lib/nerdtree/bookmark.vim index 9024077..d56407f 100644 --- a/lib/nerdtree/bookmark.vim +++ b/lib/nerdtree/bookmark.vim @@ -1,5 +1,13 @@ -"CLASS: Bookmark -"============================================================ +" ============================================================================ +" CLASS: Bookmark +" +" The Bookmark class serves two purposes: +" (1) It is the top-level prototype for new, concrete Bookmark objects. +" (2) It provides an interface for client code to query and manipulate the +" global list of Bookmark objects within the current Vim session. +" ============================================================================ + + let s:Bookmark = {} let g:NERDTreeBookmark = s:Bookmark