code: public <T> T getInterface(String objectName, Class<T> clazz) {
      Invocable inv = (Invocable) engine;
      Object o = engine.get(objectName);
      if (o == null) {
        return null;
      }
      return inv.getInterface(o, clazz);
    }
docs: <p> Gets an object created in the scripting environment and converts it to a Java Interface. </p>
  
  @param <T>        The type of the Java Interface
  @param objectName The name of the object in the script
  @param clazz      The class information for the Java interface
  @return The object as the Java interface or null if the object does not exist