@Test public void proxyFunctions() throws Exception { System.out.println(" proxy functions"); String[] names = { "x", "y", "width", "height", "size" }; for (String name : names) { FunctionInfo info = FunctionLookup.getInfo(name, null); assertNotNull(info); assertTrue(info.isProxy()); } }
public static FunctionInfo getInfo(String jiffleName, JiffleType ...argTypes) throws UndefinedFunctionException { List<FunctionInfo> fns = lookup.get(jiffleName); if (fns != null) { for (FunctionInfo info : fns) { if (info.matches(jiffleName, argTypes)) { return info; } } } throw new UndefinedFunctionException( String.format( "Undefined function: %s(%s)", jiffleName, Strings.commas((Object[])argTypes) )); }
FunctionLookup { public static FunctionInfo getInfo(String jiffleName, JiffleType ...argTypes) throws UndefinedFunctionException { List<FunctionInfo> fns = lookup.get(jiffleName); if (fns != null) { for (FunctionInfo info : fns) { if (info.matches(jiffleName, argTypes)) { return info; } } } throw new UndefinedFunctionException( String.format( "Undefined function: %s(%s)", jiffleName, Strings.commas((Object[])argTypes) )); } }
FunctionLookup { public static FunctionInfo getInfo(String jiffleName, JiffleType ...argTypes) throws UndefinedFunctionException { List<FunctionInfo> fns = lookup.get(jiffleName); if (fns != null) { for (FunctionInfo info : fns) { if (info.matches(jiffleName, argTypes)) { return info; } } } throw new UndefinedFunctionException( String.format( "Undefined function: %s(%s)", jiffleName, Strings.commas((Object[])argTypes) )); }  }
FunctionLookup { public static FunctionInfo getInfo(String jiffleName, JiffleType ...argTypes) throws UndefinedFunctionException { List<FunctionInfo> fns = lookup.get(jiffleName); if (fns != null) { for (FunctionInfo info : fns) { if (info.matches(jiffleName, argTypes)) { return info; } } } throw new UndefinedFunctionException( String.format( "Undefined function: %s(%s)", jiffleName, Strings.commas((Object[])argTypes) )); }  static boolean isDefined(String jiffleName); static boolean isDefined(String jiffleName, JiffleType ...argTypes); static FunctionInfo getInfo(String jiffleName, JiffleType ...argTypes); static String getRuntimeExpr(String jiffleName, JiffleType ...argTypes); static JiffleType getReturnType(String jiffleName); }
FunctionLookup { public static FunctionInfo getInfo(String jiffleName, JiffleType ...argTypes) throws UndefinedFunctionException { List<FunctionInfo> fns = lookup.get(jiffleName); if (fns != null) { for (FunctionInfo info : fns) { if (info.matches(jiffleName, argTypes)) { return info; } } } throw new UndefinedFunctionException( String.format( "Undefined function: %s(%s)", jiffleName, Strings.commas((Object[])argTypes) )); }  static boolean isDefined(String jiffleName); static boolean isDefined(String jiffleName, JiffleType ...argTypes); static FunctionInfo getInfo(String jiffleName, JiffleType ...argTypes); static String getRuntimeExpr(String jiffleName, JiffleType ...argTypes); static JiffleType getReturnType(String jiffleName);  }