@ CallMethod ( pattern = "install/version/script" ) public void addScript ( @ CallParam ( pattern = "install/version/script" ) final String _code , @ CallParam ( pattern = "install/version/script" , attributeName = "type" ) final String _type , @ CallParam ( pattern = "install/version/script" , attributeName = "name" ) final String _name , @ CallParam ( pattern = "install/version/script" , attributeName = "function" ) final String _function ) { AbstractScript script = null ; if ( "rhino" . equalsIgnoreCase ( _type ) ) { script = new RhinoScript ( _code , _name , _function ) ; } else if ( "groovy" . equalsIgnoreCase ( _type ) ) { script = new GroovyScript ( _code , _name , _function ) ; } if ( script != null ) { this . scripts . add ( script ) ; } }
Adds a new Script to this version .