Guest User

Untitled

a guest
Apr 23rd, 2018
83
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.42 KB | None | 0 0
  1. (defn wall-hack-method
  2. "params is a vector of class which correspond to the arguments to the method
  3. obj is nil for static methods, the instance object otherwise
  4. the method name is given as a symbol or a keyword (something Named)"
  5. [class-name name- params obj & args]
  6. (-> class-name (.getDeclaredMethod (name name-) (into-array Class params))
  7. (doto (.setAccessible true))
  8. (.invoke obj (into-array Object args))))
Add Comment
Please, Sign In to add comment