496 lines
24 KiB
HTML
496 lines
24 KiB
HTML
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
|
|
<!-- **************************************************************** -->
|
|
<!-- * PLEASE KEEP COMPLICATED EXPRESSIONS OUT OF THESE TEMPLATES, * -->
|
|
<!-- * i.e. only iterate & print data where possible. Thanks, Jez. * -->
|
|
<!-- **************************************************************** -->
|
|
|
|
<html>
|
|
<head>
|
|
<!-- Generated by groovydoc (2.3.3) on Fri Jul 31 01:11:23 PDT 2015 -->
|
|
<title>JRubyExec (jruby-gradle-base-plugin 1.0.0 API)</title>
|
|
<meta name="date" content="2015-07-31">
|
|
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
|
<link href="../../../groovy.ico" type="image/x-icon" rel="shortcut icon">
|
|
<link href="../../../groovy.ico" type="image/x-icon" rel="icon">
|
|
<link rel="stylesheet" type="text/css" href="../../../stylesheet.css" title="Style">
|
|
|
|
<body class="center">
|
|
<script type="text/javascript"><!--
|
|
if (location.href.indexOf('is-external=true') == -1) {
|
|
parent.document.title="JRubyExec (jruby-gradle-base-plugin 1.0.0 API)";
|
|
}
|
|
//-->
|
|
</script>
|
|
<noscript>
|
|
<div>JavaScript is disabled on your browser.</div>
|
|
</noscript>
|
|
<!-- ========= START OF TOP NAVBAR ======= -->
|
|
<div class="topNav"><a name="navbar_top">
|
|
<!-- -->
|
|
</a><a href="#skip-navbar_top" title="Skip navigation links"></a><a name="navbar_top_firstrow">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="navList" title="Navigation">
|
|
<li><a href="../../../overview-summary.html">Overview</a></li>
|
|
<li><a href="package-summary.html">Package</a></li>
|
|
<li class="navBarCell1Rev">Class</li>
|
|
<li><a href="../../../deprecated-list.html">Deprecated</a></li>
|
|
<li><a href="../../../index-all.html">Index</a></li>
|
|
<li><a href="../../../help-doc.html">Help</a></li>
|
|
</ul>
|
|
</div>
|
|
|
|
<div class="subNav">
|
|
<div>
|
|
<ul class="navList">
|
|
<li><a href="../../../index.html?com/github/jrubygradle/JRubyExec" target="_top">Frames</a></li>
|
|
<li><a href="JRubyExec.html" target="_top">No Frames</a></li>
|
|
</ul>
|
|
</div>
|
|
<div>
|
|
<ul class="subNavList">
|
|
<li>Summary: </li>
|
|
Nested Field <li><a href="#constructor_summary">Constructor</a></li> <li><a href="#method_summary">Method</a></li>
|
|
</ul>
|
|
<ul class="subNavList">
|
|
<li> | Detail: </li>
|
|
Field <li><a href="#constructor_detail">Constructor</a></li> <li><a href="#method_detail">Method</a></li>
|
|
</ul>
|
|
</div>
|
|
<a name="skip-navbar_top">
|
|
<!-- -->
|
|
</a></div>
|
|
<!-- ========= END OF TOP NAVBAR ========= -->
|
|
|
|
<!-- ======== START OF CLASS DATA ======== -->
|
|
<div class="header">
|
|
|
|
<div class="subTitle">Package: <strong>com.github.jrubygradle</strong></div>
|
|
|
|
<h2 title="[Groovy] Class JRubyExec" class="title">[Groovy] Class JRubyExec</h2>
|
|
</div>
|
|
<div class="contentContainer">
|
|
<ul class="inheritance">
|
|
<li><ul class="inheritance"></ul></li><li><ul class="inheritance"></ul></li><li>com.github.jrubygradle.JRubyExec
|
|
</ul>
|
|
<div class="description">
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
|
|
<dl>
|
|
<dt>All Implemented Interfaces and Traits:</dt>
|
|
<dd><a href='../../../com/github/jrubygradle/internal/JRubyExecTraits.html'>JRubyExecTraits</a></dd>
|
|
</dl>
|
|
<!-- todo: direct known subclasses -->
|
|
<hr>
|
|
<br>
|
|
<pre>class JRubyExec
|
|
extends <a href='../../../org.gradle.api.tasks.JavaExec.html'>JavaExec</a>
|
|
|
|
</pre>
|
|
|
|
|
|
|
|
<p> Runs a ruby script using JRuby
|
|
<DL><DT><B>Authors:</B></DT><DD>Schalk W. Cronjé</DD></DL></p>
|
|
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
|
|
<div class="summary">
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<!-- =========== NESTED CLASS SUMMARY =========== -->
|
|
|
|
|
|
<!-- =========== ENUM CONSTANT SUMMARY =========== -->
|
|
|
|
<!-- =========== FIELD SUMMARY =========== -->
|
|
|
|
|
|
<!-- =========== PROPERTY SUMMARY =========== -->
|
|
|
|
|
|
<!-- =========== ELEMENT SUMMARY =========== -->
|
|
|
|
|
|
|
|
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
|
|
<ul class="blockList">
|
|
<li class="blockList"><a name="constructor_summary"><!-- --></a>
|
|
<h3>Constructor Summary</h3>
|
|
<ul class="blockList">
|
|
<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Constructors Summary table">
|
|
<caption><span>Constructors</span><span class="tabEnd"> </span></caption>
|
|
<tr>
|
|
<th class="colFirst" scope="col">Constructor and description</th>
|
|
</tr>
|
|
|
|
<tr class="altColor">
|
|
<td class="colFirst">
|
|
<code><a href="#JRubyExec()">JRubyExec</a></strong>
|
|
()</code><br></td>
|
|
</tr>
|
|
|
|
</table>
|
|
</ul>
|
|
</li>
|
|
</ul>
|
|
|
|
|
|
|
|
<!-- ========== METHOD SUMMARY =========== -->
|
|
<ul class="blockList">
|
|
|
|
<li class="blockList"><a name="method_summary"><!-- --></a>
|
|
<h3>Methods Summary</h3>
|
|
<ul class="blockList">
|
|
<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Methods Summary table">
|
|
<caption><span>Methods</span><span class="tabEnd"> </span></caption>
|
|
<tr>
|
|
<th class="colFirst" scope="col">Type</th>
|
|
<th class="colLast" scope="col">Name and description</th>
|
|
</tr>
|
|
|
|
<tr class="altColor">
|
|
<td class="colFirst"><code><a href='../../../JavaExec.html'>JavaExec</a></strong></code></td>
|
|
<td class="colLast"><code><strong><a href="#args(java.lang.Object)">args</a></strong>(java.lang.Object... args)</code><br></td>
|
|
</tr>
|
|
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><code><a href='../../../JavaExecSpec.html'>JavaExecSpec</a></strong></code></td>
|
|
<td class="colLast"><code><strong><a href="#args(Iterable<?>)">args</a></strong>(java.lang.Iterable<?> args)</code><br></td>
|
|
</tr>
|
|
|
|
<tr class="altColor">
|
|
<td class="colFirst"><code>void</strong></code></td>
|
|
<td class="colLast"><code><strong><a href="#exec()">exec</a></strong>()</code><br></td>
|
|
</tr>
|
|
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><code>java.util.List<java.lang.String></strong></code></td>
|
|
<td class="colLast"><code><strong><a href="#getArgs()">getArgs</a></strong>()</code><br>getArgs gets overridden in order to add JRuby options, script name and script arguments in the correct order.</td>
|
|
</tr>
|
|
|
|
<tr class="altColor">
|
|
<td class="colFirst"><code>java.util.List<java.lang.String></strong></code></td>
|
|
<td class="colLast"><code><strong><a href="#getJrubyArgs()">getJrubyArgs</a></strong>()</code><br>Returns a list of jruby arguments</td>
|
|
</tr>
|
|
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><code>java.lang.String</strong></code></td>
|
|
<td class="colLast"><code><strong><a href="#getJrubyVersion()">getJrubyVersion</a></strong>()</code><br>If it is required that a JRubyExec task needs to be executed with a different version of JRuby that the
|
|
globally configured one, it can be done by setting it here.</td>
|
|
</tr>
|
|
|
|
<tr class="altColor">
|
|
<td class="colFirst"><code>java.io.File</strong></code></td>
|
|
<td class="colLast"><code><strong><a href="#getScript()">getScript</a></strong>()</code><br>Script to execute.</td>
|
|
</tr>
|
|
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><code>java.util.List<java.lang.Object></strong></code></td>
|
|
<td class="colLast"><code><strong><a href="#getScriptArgs()">getScriptArgs</a></strong>()</code><br>Returns a list of script arguments</td>
|
|
</tr>
|
|
|
|
<tr class="altColor">
|
|
<td class="colFirst"><code>static java.lang.String</strong></code></td>
|
|
<td class="colLast"><code><strong><a href="#jarDependenciesGemLibPath(java.io.File)">jarDependenciesGemLibPath</a></strong>(java.io.File gemDir)</code><br></td>
|
|
</tr>
|
|
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><code>void</strong></code></td>
|
|
<td class="colLast"><code><strong><a href="#jrubyVersion(java.lang.String)">jrubyVersion</a></strong>(java.lang.String ver)</code><br>Setting the <CODE>jruby-complete</CODE> version allows for tasks to be run using different versions of JRuby.
|
|
</td>
|
|
</tr>
|
|
|
|
<tr class="altColor">
|
|
<td class="colFirst"><code><a href='../../../JavaExec.html'>JavaExec</a></strong></code></td>
|
|
<td class="colLast"><code><strong><a href="#setArgs(Iterable<?>)">setArgs</a></strong>(java.lang.Iterable<?> applicationArgs)</code><br></td>
|
|
</tr>
|
|
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><code>void</strong></code></td>
|
|
<td class="colLast"><code><strong><a href="#setJrubyVersion(java.lang.String)">setJrubyVersion</a></strong>(java.lang.String version)</code><br>Setting the <CODE>jruby-complete</CODE> version allows for tasks to be run using different versions of JRuby.
|
|
</td>
|
|
</tr>
|
|
|
|
<tr class="altColor">
|
|
<td class="colFirst"><code><a href='../../../JavaExec.html'>JavaExec</a></strong></code></td>
|
|
<td class="colLast"><code><strong><a href="#setMain(java.lang.String)">setMain</a></strong>(java.lang.String mainClassName)</code><br></td>
|
|
</tr>
|
|
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><code>static void</strong></code></td>
|
|
<td class="colLast"><code><strong><a href="#updateJRubyDependencies(Project)">updateJRubyDependencies</a></strong>(<a href='../../../Project.html'>Project</a> project)</code><br>Ensure that our JRuby depedencies are updated properly for the default jrubyExec configuration
|
|
and all other JRubyExec tasks</td>
|
|
</tr>
|
|
|
|
<tr class="altColor">
|
|
<td class="colFirst"><code>void</strong></code></td>
|
|
<td class="colLast"><code><strong><a href="#validateTaskConfiguration()">validateTaskConfiguration</a></strong>()</code><br>Verify that we are in a good configuration for execution</td>
|
|
</tr>
|
|
|
|
</table>
|
|
</ul>
|
|
</li>
|
|
|
|
</ul>
|
|
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
|
|
<div class="details">
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<!-- =========== CONSTRUCTOR DETAIL =========== -->
|
|
<ul class="blockList">
|
|
<li class="blockList"><a name="constructor_detail">
|
|
<!-- -->
|
|
</a>
|
|
<h3>Constructor Detail</h3>
|
|
|
|
<a name="JRubyExec()"><!-- --></a>
|
|
<ul class="blockListLast">
|
|
<li class="blockList">
|
|
<h4><strong>JRubyExec</strong>()</h4>
|
|
<p></p>
|
|
</li>
|
|
</ul>
|
|
|
|
</li>
|
|
</ul>
|
|
|
|
|
|
|
|
|
|
<!-- =========== METHOD DETAIL =========== -->
|
|
<ul class="blockList">
|
|
<li class="blockList"><a name="method_detail">
|
|
<!-- -->
|
|
</a>
|
|
<h3>Method Detail</h3>
|
|
|
|
<a name="args(java.lang.Object)"><!-- --></a>
|
|
<ul class="blockListLast">
|
|
<li class="blockList">
|
|
<h4>@java.lang.Override
|
|
<a href='../../../JavaExec.html'>JavaExec</a> <strong>args</strong>(java.lang.Object... args)</h4>
|
|
<p></p>
|
|
</li>
|
|
</ul>
|
|
|
|
<a name="args(Iterable<?>)"><!-- --></a>
|
|
<ul class="blockListLast">
|
|
<li class="blockList">
|
|
<h4>@java.lang.Override
|
|
<a href='../../../JavaExecSpec.html'>JavaExecSpec</a> <strong>args</strong>(java.lang.Iterable<?> args)</h4>
|
|
<p></p>
|
|
</li>
|
|
</ul>
|
|
|
|
<a name="exec()"><!-- --></a>
|
|
<ul class="blockListLast">
|
|
<li class="blockList">
|
|
<h4>@java.lang.Override
|
|
void <strong>exec</strong>()</h4>
|
|
<p></p>
|
|
</li>
|
|
</ul>
|
|
|
|
<a name="getArgs()"><!-- --></a>
|
|
<ul class="blockListLast">
|
|
<li class="blockList">
|
|
<h4>@java.lang.Override
|
|
java.util.List<java.lang.String> <strong>getArgs</strong>()</h4>
|
|
<p> getArgs gets overridden in order to add JRuby options, script name and script arguments in the correct order.
|
|
|
|
There are three modes of behaviour
|
|
<ul>
|
|
<li> script set. no jrubyArgs, or jrubyArgs does not contain <CODE>-S</CODE> - Normal way to execute script. A check
|
|
whether the script exists will be performed.
|
|
<li> script set. jrubyArgs contains <CODE>-S</CODE> - If script is not absolute, no check will be performed to see
|
|
if the script exists and will be assumed that the script can be found using the default ruby path mechanism.
|
|
<li> script not set, but jrubyArgs set - Set up to execute jruby with no script. This should be a rarely used otion.
|
|
</ul>
|
|
<DL><DT><B>Throws:</B></DT><DD><CODE>org.gradle.api.InvalidUserDataException</CODE> if mode of behaviour cannot be determined.</DD></DL></p>
|
|
</li>
|
|
</ul>
|
|
|
|
<a name="getJrubyArgs()"><!-- --></a>
|
|
<ul class="blockListLast">
|
|
<li class="blockList">
|
|
<h4>@java.util.Optional
|
|
@Input
|
|
java.util.List<java.lang.String> <strong>getJrubyArgs</strong>()</h4>
|
|
<p> Returns a list of jruby arguments
|
|
</p>
|
|
</li>
|
|
</ul>
|
|
|
|
<a name="getJrubyVersion()"><!-- --></a>
|
|
<ul class="blockListLast">
|
|
<li class="blockList">
|
|
<h4>@Input
|
|
java.lang.String <strong>getJrubyVersion</strong>()</h4>
|
|
<p> If it is required that a JRubyExec task needs to be executed with a different version of JRuby that the
|
|
globally configured one, it can be done by setting it here.
|
|
</p>
|
|
</li>
|
|
</ul>
|
|
|
|
<a name="getScript()"><!-- --></a>
|
|
<ul class="blockListLast">
|
|
<li class="blockList">
|
|
<h4>@java.util.Optional
|
|
@Input
|
|
java.io.File <strong>getScript</strong>()</h4>
|
|
<p> Script to execute.
|
|
<DL><DT><B>Returns:</B></DT><DD>The path to the script (or nul if not set)</DD></DL></p>
|
|
</li>
|
|
</ul>
|
|
|
|
<a name="getScriptArgs()"><!-- --></a>
|
|
<ul class="blockListLast">
|
|
<li class="blockList">
|
|
<h4>@java.util.Optional
|
|
@Input
|
|
java.util.List<java.lang.Object> <strong>getScriptArgs</strong>()</h4>
|
|
<p> Returns a list of script arguments
|
|
</p>
|
|
</li>
|
|
</ul>
|
|
|
|
<a name="jarDependenciesGemLibPath(java.io.File)"><!-- --></a>
|
|
<ul class="blockListLast">
|
|
<li class="blockList">
|
|
<h4>static java.lang.String <strong>jarDependenciesGemLibPath</strong>(java.io.File gemDir)</h4>
|
|
<p></p>
|
|
</li>
|
|
</ul>
|
|
|
|
<a name="jrubyVersion(java.lang.String)"><!-- --></a>
|
|
<ul class="blockListLast">
|
|
<li class="blockList">
|
|
<h4>void <strong>jrubyVersion</strong>(java.lang.String ver)</h4>
|
|
<p> Setting the <CODE>jruby-complete</CODE> version allows for tasks to be run using different versions of JRuby.
|
|
This is useful for comparing the results of different version or running with a gem that is only
|
|
compatible with a specific version or when running a script with a different version that what will
|
|
be packaged.
|
|
<DL><DT><B>Parameters:</B></DT><DD><code>version</code> - String in the form '1.7.13'</DD></DL><DL><DT><B>Since:</B></DT><DD>0.1.18</DD></DL></p>
|
|
</li>
|
|
</ul>
|
|
|
|
<a name="setArgs(Iterable<?>)"><!-- --></a>
|
|
<ul class="blockListLast">
|
|
<li class="blockList">
|
|
<h4>@java.lang.Override
|
|
<a href='../../../JavaExec.html'>JavaExec</a> <strong>setArgs</strong>(java.lang.Iterable<?> applicationArgs)</h4>
|
|
<p></p>
|
|
</li>
|
|
</ul>
|
|
|
|
<a name="setJrubyVersion(java.lang.String)"><!-- --></a>
|
|
<ul class="blockListLast">
|
|
<li class="blockList">
|
|
<h4>void <strong>setJrubyVersion</strong>(java.lang.String version)</h4>
|
|
<p> Setting the <CODE>jruby-complete</CODE> version allows for tasks to be run using different versions of JRuby.
|
|
This is useful for comparing the results of different version or running with a gem that is only
|
|
compatible with a specific version or when running a script with a different version that what will
|
|
be packaged.
|
|
<DL><DT><B>Parameters:</B></DT><DD><code>version</code> - String in the form '1.7.13'</DD></DL></p>
|
|
</li>
|
|
</ul>
|
|
|
|
<a name="setMain(java.lang.String)"><!-- --></a>
|
|
<ul class="blockListLast">
|
|
<li class="blockList">
|
|
<h4>@java.lang.Override
|
|
<a href='../../../JavaExec.html'>JavaExec</a> <strong>setMain</strong>(java.lang.String mainClassName)</h4>
|
|
<p></p>
|
|
</li>
|
|
</ul>
|
|
|
|
<a name="updateJRubyDependencies(Project)"><!-- --></a>
|
|
<ul class="blockListLast">
|
|
<li class="blockList">
|
|
<h4>static void <strong>updateJRubyDependencies</strong>(<a href='../../../Project.html'>Project</a> project)</h4>
|
|
<p> Ensure that our JRuby depedencies are updated properly for the default jrubyExec configuration
|
|
and all other JRubyExec tasks
|
|
|
|
This function also ensures that we have a proper version of jar-dependencies
|
|
on older versions of JRuby so jar requires work properly on those version
|
|
<DL><DT><B>Parameters:</B></DT><DD>project</DD></DL><DL><DT><B>Since:</B></DT><DD>1.0.0</DD></DL></p>
|
|
</li>
|
|
</ul>
|
|
|
|
<a name="validateTaskConfiguration()"><!-- --></a>
|
|
<ul class="blockListLast">
|
|
<li class="blockList">
|
|
<h4>void <strong>validateTaskConfiguration</strong>()</h4>
|
|
<p> Verify that we are in a good configuration for execution </p>
|
|
</li>
|
|
</ul>
|
|
|
|
</li>
|
|
</ul>
|
|
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
|
|
<!-- ========= END OF CLASS DATA ========= -->
|
|
<!-- ======= START OF BOTTOM NAVBAR ====== -->
|
|
<div class="bottomNav"><a name="navbar_bottom">
|
|
<!-- -->
|
|
</a><a href="#skip-navbar_bottom" title="Skip navigation links"></a><a name="navbar_bottom_firstrow">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="navList" title="Navigation">
|
|
<li><a href="../../../overview-summary.html">Overview</a></li>
|
|
<li><a href="package-summary.html">Package</a></li>
|
|
<li class="navBarCell1Rev">Class</li>
|
|
<li><a href="../../../deprecated-list.html">Deprecated</a></li>
|
|
<li><a href="../../../index-all.html">Index</a></li>
|
|
<li><a href="../../../help-doc.html">Help</a></li>
|
|
</ul>
|
|
</div>
|
|
|
|
<div class="subNav">
|
|
<div>
|
|
<ul class="navList">
|
|
<li><a href="../../../index.html?com/github/jrubygradle/JRubyExec" target="_top">Frames</a></li>
|
|
<li><a href="JRubyExec.html" target="_top">No Frames</a></li>
|
|
</ul>
|
|
</div>
|
|
<div>
|
|
<ul class="subNavList">
|
|
<li>Summary: </li>
|
|
Nested Field <li><a href="#constructor_summary">Constructor</a></li> <li><a href="#method_summary">Method</a></li>
|
|
</ul>
|
|
<ul class="subNavList">
|
|
<li> | Detail: </li>
|
|
Field <li><a href="#constructor_detail">Constructor</a></li> <li><a href="#method_detail">Method</a></li>
|
|
</ul>
|
|
</div>
|
|
<p>Groovy Documentation</p>
|
|
<a name="skip-navbar_bottom">
|
|
<!-- -->
|
|
</a>
|
|
</div>
|
|
</div>
|
|
<!-- ======== END OF BOTTOM NAVBAR ======= -->
|
|
</body>
|
|
</html>
|