artdaq_node_server
v1_00_08
Main Page
Related Pages
Namespaces
Classes
Files
Examples
File List
File Members
All
Classes
Namespaces
Files
Variables
Pages
src
node_modules
xml2js
node_modules
xmlbuilder
node_modules
lodash
negate.js
1
2
var FUNC_ERROR_TEXT =
'Expected a function'
;
3
24
function
negate(predicate) {
25
if
(typeof predicate !=
'function'
) {
26
throw
new
TypeError(FUNC_ERROR_TEXT);
27
}
28
return
function
() {
29
var args = arguments;
30
switch
(args.length) {
31
case
0:
return
!predicate.call(
this
);
32
case
1:
return
!predicate.call(
this
, args[0]);
33
case
2:
return
!predicate.call(
this
, args[0], args[1]);
34
case
3:
return
!predicate.call(
this
, args[0], args[1], args[2]);
35
}
36
return
!predicate.apply(
this
, args);
37
};
38
}
39
40
module.exports = negate;
Generated on Thu Jun 1 2017 12:07:36 for artdaq_node_server by
1.8.5