result() method from fcf.Actions class
Class:
Package: fcf-framework-core
File: fcf.js
Available from version: 2.0.2
Gets or sets the result of executing an object depending on the arguments passed
If the
If the function is called with no arguments, it returns the currently set result of the asynchronous operations.
Arguments
- A new set value for the result of asynchronous operations
Result
- If an argument a_value is passed, then a pointer to itself.
If the function is called without arguments, then the current value of the result of performing asynchronous operations is returned.
Example: Get value
let actions = new fcf.Actions();
actions .then (()=>{
return "Result value";
});
console.log(actions .result ());
Output:
Result value
Example: Set value
let actions = new fcf.Actions();
actions .result ("Result value");
actions .then ((a_lastResutl)=>{
console.log(a_lastResutl);
});
Output:
Result value
VPSDime is an industry leading VPS hosting company that provides virtualized server services with high performance, availability and friendly support.