Uploaded image for project: 'ZK'
  1. ZK
  2. ZK-4772

Adding annotations like @Command/@DependsOn/@NotifyChange not possible in Zscript/BeanShell

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open
    • Priority: Normal
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: Databind 2
    • Labels:
      None

      Description

      One of ZK's strengths is rapid prototyping using Zscript classes (which are built using BeanShell). Databind 2 highly relies on Java annotations like @Command/@DependsOn/@NotifyChange, which are not supported by BeanShell. Therefore, one always has to implement real Java classes, methods of Beanshell subclasses cannot have the necessary annotations.

      Triggering load/save operations by events directly, like @load(some.bean, after='textbox.onChange'), which would allow developers to work around this, are not supported either. Is this step backwards in terms of flexibility intended, or is the Databind 2 design not matured yet?

      Is there any way of defining the annotations in XML files or adding them programmatically?

        Attachments

          Activity

            People

            Assignee:
            Unassigned Unassigned
            Reporter:
            chemFelix chemFelix
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Dates

              Created:
              Updated: