Package util
Class Helper
java.lang.Object
util.Helper
- Author:
- Krish Pillai
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic booleancheckCallStackForMethod(String method) Utility function to check if the caller is authorized.static StringFind the name of the method that invoked this method.
-
Constructor Details
-
Helper
public Helper()
-
-
Method Details
-
checkCallStackForMethod
Utility function to check if the caller is authorized. Checks to see if the specified call-chain is part of the stack-trace. Returns a true if the argument shows up in the stack trace of the current thread.- Parameters:
method- The method in question- Returns:
- true if authorized
-
getCurrentMethodName
Find the name of the method that invoked this method.- Returns:
- the name of the caller
-