Class VariableResolverInfo

java.lang.Object
org.zkoss.zk.ui.metainfo.VariableResolverInfo

public class VariableResolverInfo extends Object
A definition of the variable resolver (VariableResolver).

Note: we resolve the class by using Classes.forNameByThread. In other words, it doesn't support the class defined in zscript. Why not? Since there is no way to run zscript before the variable-resolver directive (and better performance).

Note: it is not serializable.

Author:
tomyeh
  • Constructor Details

    • VariableResolverInfo

      public VariableResolverInfo(Class<? extends org.zkoss.xel.VariableResolver> cls, Map<String,String> args)
      Constructs with a class.
      Parameters:
      args - the map of arguments. Ignored if null.
      Notice that, once assigned, the map belongs to this object, and the caller shall not access it again
      Since:
      3.6.2
    • VariableResolverInfo

      public VariableResolverInfo(Class<? extends org.zkoss.xel.VariableResolver> cls)
      Constructs with a class.
    • VariableResolverInfo

      public VariableResolverInfo(String clsnm, Map<String,String> args) throws ClassNotFoundException
      Constructs with a class name.
      Parameters:
      clsnm - the class name; it could be an EL expression.
      Throws:
      ClassNotFoundException
      Since:
      3.6.2
    • VariableResolverInfo

      public VariableResolverInfo(String clsnm) throws ClassNotFoundException
      Constructs with a class name.
      Parameters:
      clsnm - the class name; it could be an EL expression.
      Throws:
      ClassNotFoundException
    • VariableResolverInfo

      public VariableResolverInfo(org.zkoss.xel.VariableResolver resolver)
      Constructs with an initiator that will be reuse each time newVariableResolver(org.zkoss.zk.ui.metainfo.PageDefinition, org.zkoss.zk.ui.Page) is called.
  • Method Details

    • newVariableResolver

      public org.zkoss.xel.VariableResolver newVariableResolver(PageDefinition pgdef, Page page) throws Exception
      Creates and returns the variable resolver for the specified page.
      Throws:
      Exception
    • newVariableResolver

      public org.zkoss.xel.VariableResolver newVariableResolver(Evaluator eval, Page page) throws Exception
      Creates and returns the variable resolver for the specified page.
      Throws:
      Exception
      Since:
      3.6.2
    • toString

      public String toString()
      Overrides:
      toString in class Object