Uploaded image for project: 'UIMA'
  1. UIMA
  2. UIMA-157

CAS / CasView API refactoring

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 2.1
    • Core Java Framework
    • None

    Description

      1. Goals

      The following are confusing (or some might say, "broken")

      (a) the interface "CAS" can be an interface to either the whole CAS or to a
      view. Methods like this are poor:
      CAS view = cas.getView(name);

      (b) the logic determining which "CAS" (a view or the whole CAS) gets
      passed to an
      annotator's process method is needlessly complicated.

      We would like to improve this in v2.1, so we have a short runway to implement it. It's acceptable if what we do breaks multi-view
      annotators/applicatoins, but it cannot break single-view annotators/applications.

      We want whatever we do to be easier to document and explain to users
      than what we currently have.

      2. Proposed Solution

      We don't plan to change the fundamental design of views at this point

      • there isn't time and it's too controversial. A view still consists
        of an index repository and a Sofa. (Yes, I know someday a view may
        not have a Sofa - but for now, it does.)

      A. New CasView interface

      We create a new interface CasView. All of the CAS.getView() methods
      will now return type CasView (instead of CAS).

      The CasView interface will contain all of the sofa-access methods and
      indexing-related methods that are on the CAS interface.

      Further discussion: http://www.mail-archive.com/uima-dev@incubator.apache.org/msg00945.html
      Proposed sets of methods on each interface: http://cwiki.apache.org/UIMA/casandcasviewinterfaceredesign.html

      Attachments

        Activity

          People

            alally Adam P. Lally
            alally Adam P. Lally
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: