<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.idempiere.org/w-en/index.php?action=history&amp;feed=atom&amp;title=NF9_Annotated_Process_Parameters</id>
	<title>NF9 Annotated Process Parameters - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.idempiere.org/w-en/index.php?action=history&amp;feed=atom&amp;title=NF9_Annotated_Process_Parameters"/>
	<link rel="alternate" type="text/html" href="https://wiki.idempiere.org/w-en/index.php?title=NF9_Annotated_Process_Parameters&amp;action=history"/>
	<updated>2026-10-01T05:45:15Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.35.2</generator>
	<entry>
		<id>https://wiki.idempiere.org/w-en/index.php?title=NF9_Annotated_Process_Parameters&amp;diff=20844&amp;oldid=prev</id>
		<title>Hengsin: /* Feature: Annotated Process Parameters */</title>
		<link rel="alternate" type="text/html" href="https://wiki.idempiere.org/w-en/index.php?title=NF9_Annotated_Process_Parameters&amp;diff=20844&amp;oldid=prev"/>
		<updated>2023-03-08T08:59:54Z</updated>

		<summary type="html">&lt;p&gt;&lt;span dir=&quot;auto&quot;&gt;&lt;span class=&quot;autocomment&quot;&gt;Feature: Annotated Process Parameters&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;table class=&quot;diff diff-contentalign-left diff-editfont-monospace&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 08:59, 8 March 2023&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l84&quot; &gt;Line 84:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 84:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:New Features v9|A]]&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:New Features v9|A]]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:New Features Development]]&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt; &lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:New Features Development]]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt; &lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;[[Category:Annotations]]&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;

&lt;!-- diff cache key idempiere-en-:diff::1.12:old-20010:rev-20844 --&gt;
&lt;/table&gt;</summary>
		<author><name>Hengsin</name></author>
	</entry>
	<entry>
		<id>https://wiki.idempiere.org/w-en/index.php?title=NF9_Annotated_Process_Parameters&amp;diff=20010&amp;oldid=prev</id>
		<title>Sjg: Created page with &quot;= '''Feature:''' Annotated Process Parameters =  '''Goal:''' Development  '''Developer:''' Saulo Gil  '''Feature Ticket:''' [https://idempiere.atlassian.net/brows...&quot;</title>
		<link rel="alternate" type="text/html" href="https://wiki.idempiere.org/w-en/index.php?title=NF9_Annotated_Process_Parameters&amp;diff=20010&amp;oldid=prev"/>
		<updated>2022-03-14T02:20:23Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;= &amp;#039;&amp;#039;&amp;#039;Feature:&amp;#039;&amp;#039;&amp;#039; Annotated Process Parameters =  &amp;#039;&amp;#039;&amp;#039;Goal:&amp;#039;&amp;#039;&amp;#039; Development  &amp;#039;&amp;#039;&amp;#039;Developer:&amp;#039;&amp;#039;&amp;#039; &lt;a href=&quot;/w-en/index.php?title=User:Sjg&amp;amp;action=edit&amp;amp;redlink=1&quot; class=&quot;new&quot; title=&quot;User:Sjg (page does not exist)&quot;&gt;Saulo Gil&lt;/a&gt;  &amp;#039;&amp;#039;&amp;#039;Feature Ticket:&amp;#039;&amp;#039;&amp;#039; [https://idempiere.atlassian.net/brows...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;= '''Feature:''' Annotated Process Parameters =&lt;br /&gt;
&lt;br /&gt;
'''Goal:''' Development&lt;br /&gt;
&lt;br /&gt;
'''Developer:''' [[User:Sjg|Saulo Gil]]&lt;br /&gt;
&lt;br /&gt;
'''Feature Ticket:''' [https://idempiere.atlassian.net/browse/IDEMPIERE-5025 IDEMPIERE-5025]&lt;br /&gt;
&lt;br /&gt;
'''Description:'''&lt;br /&gt;
&lt;br /&gt;
This feature was created in order to simplify the task of reading process parameters by using the new @Parameter annotation. Here's a comparison between new and the traditional way of achieving this goal, using the OrderBatchProcess class as reference.&lt;br /&gt;
&lt;br /&gt;
''Using this feature''&lt;br /&gt;
&lt;br /&gt;
  @org.adempiere.base.annotation.Process&lt;br /&gt;
  public class OrderBatchProcess extends SvrProcess&lt;br /&gt;
  {&lt;br /&gt;
    @Parameter&lt;br /&gt;
    private int      p_C_DocTypeTarget_ID = 0;&lt;br /&gt;
    @Parameter&lt;br /&gt;
    private String     p_DocStatus = null;&lt;br /&gt;
    @Parameter&lt;br /&gt;
    private int      p_C_BPartner_ID = 0;&lt;br /&gt;
    @Parameter&lt;br /&gt;
    private String     p_IsSelfService = null;&lt;br /&gt;
    @Parameter&lt;br /&gt;
    private Timestamp  p_DateOrdered_From = null;&lt;br /&gt;
    @Parameter&lt;br /&gt;
    private Timestamp  p_DateOrdered_To = null;&lt;br /&gt;
    @Parameter&lt;br /&gt;
    private String     p_DocAction = null;&lt;br /&gt;
    @Parameter&lt;br /&gt;
    private String     p_IsDelivered = null;&lt;br /&gt;
    @Parameter&lt;br /&gt;
    private String     p_IsInvoiced = null;&lt;br /&gt;
  &lt;br /&gt;
    protected void prepare (){ /* nothing else to do here */ }&lt;br /&gt;
  }&lt;br /&gt;
&lt;br /&gt;
''Traditional way''&lt;br /&gt;
&lt;br /&gt;
  protected void prepare ()&lt;br /&gt;
  {&lt;br /&gt;
    ProcessInfoParameter[] para = getParameter();&lt;br /&gt;
    for (int i = 0; i &amp;lt; para.length; i++)&lt;br /&gt;
    {&lt;br /&gt;
      String name = para[i].getParameterName();&lt;br /&gt;
      if (para[i].getParameter() == null &amp;amp;&amp;amp; para[i].getParameter_To() == null)&lt;br /&gt;
        ;&lt;br /&gt;
      else if (name.equals(&amp;quot;C_DocTypeTarget_ID&amp;quot;))&lt;br /&gt;
        p_C_DocTypeTarget_ID = para[i].getParameterAsInt();&lt;br /&gt;
      else if (name.equals(&amp;quot;DocStatus&amp;quot;))&lt;br /&gt;
        p_DocStatus = (String)para[i].getParameter();&lt;br /&gt;
      else if (name.equals(&amp;quot;IsSelfService&amp;quot;))&lt;br /&gt;
        p_IsSelfService = (String)para[i].getParameter();&lt;br /&gt;
      else if (name.equals(&amp;quot;C_BPartner_ID&amp;quot;))&lt;br /&gt;
        p_C_BPartner_ID = para[i].getParameterAsInt();&lt;br /&gt;
      else if (name.equals(&amp;quot;DateOrdered&amp;quot;))&lt;br /&gt;
      {&lt;br /&gt;
        p_DateOrdered_From = (Timestamp)para[i].getParameter();&lt;br /&gt;
        p_DateOrdered_To = (Timestamp)para[i].getParameter_To();&lt;br /&gt;
      }&lt;br /&gt;
      else if (name.equals(&amp;quot;DocAction&amp;quot;))&lt;br /&gt;
        p_DocAction = (String)para[i].getParameter();&lt;br /&gt;
      else if (name.equals(&amp;quot;IsDelivered&amp;quot;)) {&lt;br /&gt;
        p_IsDelivered = (String)para[i].getParameter();&lt;br /&gt;
      } else if (name.equals(&amp;quot;IsInvoiced&amp;quot;)) {&lt;br /&gt;
        p_IsInvoiced = (String)para[i].getParameter();&lt;br /&gt;
      }&lt;br /&gt;
      else&lt;br /&gt;
        log.log(Level.SEVERE, &amp;quot;Unknown Parameter: &amp;quot; + name);&lt;br /&gt;
    }&lt;br /&gt;
  }  //  prepare&lt;br /&gt;
&lt;br /&gt;
In case the class attribute name doesn't match the parameter name, we can use the name annotation attribute as follows:&lt;br /&gt;
&lt;br /&gt;
    @Parameter(name = &amp;quot;declaredName&amp;quot;)&lt;br /&gt;
    private String parameter = null;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:New Features|D]]&lt;br /&gt;
[[Category:New Features|A]]&lt;br /&gt;
[[Category:New Features v9|D]]&lt;br /&gt;
[[Category:New Features v9|A]]&lt;br /&gt;
[[Category:New Features Development]]&lt;/div&gt;</summary>
		<author><name>Sjg</name></author>
	</entry>
</feed>