MCPcopy Create free account
hub / github.com/beanshell/beanshell / unaryOperation

Method unaryOperation

src/bsh/BSHUnaryExpression.java:75–87  ·  view source on GitHub ↗
( Object op, int kind )

Source from the content-addressed store, hash-verified

73 }
74
75 private Object unaryOperation( Object op, int kind ) throws UtilEvalError
76 {
77 if (op instanceof Boolean || op instanceof Character
78 || op instanceof Number)
79 return primitiveWrapperUnaryOperation( op, kind );
80
81 if ( !(op instanceof Primitive) )
82 throw new UtilEvalError( "Unary operation " + tokenImage[kind]
83 + " inappropriate for object" );
84
85
86 return Primitive.unaryOperation((Primitive)op, kind);
87 }
88
89 private Object primitiveWrapperUnaryOperation(Object val, int kind)
90 throws UtilEvalError

Callers 2

evalMethod · 0.95
lhsUnaryOperationMethod · 0.95

Calls 2

unaryOperationMethod · 0.95

Tested by

no test coverage detected