@Override protected void doFilter(String arg0, Object arg1) { if (arg1 instanceof Object[]) { Object[] arr = (Object[]) arg1; for (int i = 0; i < arr.length; i++) { arr[i] = this.filter(arg0, arr[i]); } } }
public Object invoke(MethodInvocation arg0) throws Throwable { int d = depth.get().intValue(); if (d == 0) { sessions.cleanThread(); } Object result; d++; depth.set(d); try { result = arg0.proceed(); if (!StatefulServiceInterface.class.isAssignableFrom(arg0 .getThis().getClass())) { result = new ProxyCleanupFilter(acl, current) .filter(null, result); } } finally { d--; depth.set(d); } return result; } }
Image replacement = (Image) mapper.map(new ProxyCleanupFilter().filter("", lookups.get(image))); replacements.put(image, replacement);