tilgovi opened a new pull request #87:
URL: https://github.com/apache/incubator-annotator/pull/87


   Make several changes to eliminate unnecessary type definitions.
   
   Remove the centrally-exported selector interfaces from the selector
   package and migrate them to where they are used. The selector package
   need not commit to the existence of any particular set of selectors. In
   the future, the apache-annotator package may consolidate the existing
   selector definitions and export them under a unified namespace.
   
   Remove the matcher interface in favor of being explicit and verbose
   about function types.
   
   Simplify the type signature for makeRefinable. The selector is defined
   as an interface, thus callers are free to pass anything that extends it,
   so there is no need to parametrize its type. Use the same type
   definition for the input and output of the selector creator.
   
   Define the DOM match functions in terms of Range and place the burden on
   the caller to pass a Range. Remove the unused scope functions. This
   change may hurt the developer experience, but that will require some
   experience and feedback.
   
   Remove the "type" field from all selector definitions, since the match
   functions do not use this information. Applications may decide to
   include type information in selectors, but it is not necessary to
   dictate the specific way to achieve this. In the future, utility
   functions in the selector package may dictate this by providing a typed
   selector creator that delegates to implementations based on a type
   field.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to