Package org.jruby.anno
Annotation Interface JRubyMethod
-
Optional Element Summary
Optional ElementsModifier and TypeOptional ElementDescriptionString[]Any alias or aliases for this method.Class[]Argument types to coerce to before callingbooleanDeprecated.booleanWhether automatic arity-checking should be added to the Ruby binding for this method.booleanWhether this method expects to have a call frame allocated for it.Class[]A list of classes that implement an abstract JRubyMethod, for backtrace purposes.booleanWhether this method may recieve keyword arguments.booleanWhether this method should be defined on the metaclass.booleanWhether this method should be a module function, defined on metaclass and private on class.String[]The name or names of this method in Ruby-land.booleanWhether this method should show up as defined in response to respond_to? callsbooleanWhether to use a frame slot for backtrace informationintThe number of optional arguments.What, if anything, method reads from caller's frameintThe number of required arguments.booleanWhether this method has a "rest" argument.booleanDeprecated.The visibility of this method.What, if anything, method writes to caller's frame
-
Element Details
-
name
String[] nameThe name or names of this method in Ruby-land.- Default:
{}
-
required
int requiredThe number of required arguments.- Default:
0
-
optional
int optionalThe number of optional arguments.- Default:
0
-
rest
boolean restWhether this method has a "rest" argument.- Default:
false
-
alias
String[] aliasAny alias or aliases for this method.- Default:
{}
-
meta
boolean metaWhether this method should be defined on the metaclass.- Default:
false
-
module
boolean moduleWhether this method should be a module function, defined on metaclass and private on class.- Default:
false
-
keywords
boolean keywordsWhether this method may recieve keyword arguments. Methods may directly process the keywords or decide to pass them on to a subcall. This will determine whether ThreadContext#callInfo will get reset before the call begins or not. If keywords is true then it is the methods job to reset or not reset callInfo.- Default:
false
-
frame
boolean frameWhether this method expects to have a call frame allocated for it.- Default:
false
-
visibility
Visibility visibilityThe visibility of this method.- Default:
DEFAULT
-
reads
FrameField[] readsWhat, if anything, method reads from caller's frame- Default:
{}
-
writes
FrameField[] writesWhat, if anything, method writes to caller's frame- Default:
{}
-
argTypes
Class[] argTypesArgument types to coerce to before calling- Default:
{}
-
omit
boolean omitWhether to use a frame slot for backtrace information- Default:
false
-
notImplemented
boolean notImplementedWhether this method should show up as defined in response to respond_to? calls- Default:
false
-
checkArity
boolean checkArityWhether automatic arity-checking should be added to the Ruby binding for this method. Users can opt-out and do their own arity-checking in the method body.- Default:
true
-
implementers
Class[] implementersA list of classes that implement an abstract JRubyMethod, for backtrace purposes.- Default:
{}
-
scope
Deprecated.- Default:
false
-
backtrace
Deprecated.- Default:
false
-