Class CheckResultAcceptor

java.lang.Object
com.e1c.g5.v8.dt.internal.check.CheckResultAcceptor
All Implemented Interfaces:
ICheckResultAcceptor

public final class CheckResultAcceptor extends Object implements ICheckResultAcceptor
ICheckResultAcceptor implementation that accepta issues for specified objects and stores them in memory until the check is complete and issues are processed by the check executor Not a part of a public API, users cannot extend this class as the set of supported issues is fixed and cannot be extended by design. The calling infrastructure ensures thread safety so there is no need in synhronization.
  • Constructor Details

    • CheckResultAcceptor

      public CheckResultAcceptor(ISuppressSettingsManager suppressManager, CheckUid checkUid)
      Constructs an acceptor instance
      Parameters:
      suppressManager - Suppress manager, cannot be null
      checkId - , Check ID, cannot be null
    • CheckResultAcceptor

      public CheckResultAcceptor(ISuppressSettingsManager suppressManager, LanguageSuppressionContext suppressionContext, CheckUid checkUid)
      Constructs an acceptor instance
      Parameters:
      suppressManager - Suppress manager, cannot be null
      checkId - , Check ID, cannot be null
  • Method Details

    • addIssue

      public void addIssue(Object context, Issue issue)
      Description copied from interface: ICheckResultAcceptor
      Adds an issue for a specific object. The coordinates in the issue should match the context object otherwise the system will raise an error during the validation or will be unable to navigate to the problem later.
      Specified by:
      addIssue in interface ICheckResultAcceptor
      Parameters:
      context - The object the issue will be associated with. The marker of the issue will contain coordinates of this object in navigable form (link) as well. May not be null
      issue - Issue to add. May not be null
    • delegateChecks

      public void delegateChecks(Iterable<?> delegatedModelIterable)
      Description copied from interface: ICheckResultAcceptor
      Delegates the further checks to the set of subsidiary checks by providing some derived model with means of its traversal in the form of the iterable. This behavior may be used to perform effective checks of non-standard models being created on the fly or taken from non-standard persistent stores. Delegated models are being traversed by the EDT check engine after the main check and applicable subsidiary checks are being applied
      Specified by:
      delegateChecks in interface ICheckResultAcceptor
      Parameters:
      delegatedModelIterable - The iterable that defines the iteration through the subsidiary model. May not be null
    • getDelegatedModelIterable

      public Iterable<?> getDelegatedModelIterable()
      Gets the supplied delegated model iterable, if supplied
      Returns:
      The delegated model in the form of the iterable, may be null if the check doesn't need to delegate checks to subsidiary checks
    • getIssues

      public Map<Object,List<Issue>> getIssues()
      Gets the collected issues mapped to context objects
      Returns:
      The map of issues, may not be null, may be empty