A future method runs in the background, asynchronously. You
can call a future method for executing long-running operations, such as
callouts to external Web services or any operation you’d like to run in
its own thread, on its own time.
To define a future method, simply annotate it with the future annotation, as follows.
global class FutureClass { @future public static void myFutureMethod() { // Perform some operations } }
No comments:
Post a Comment