INTERACT FORUM

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: How do I find documentation on the new function GroupCount() and GroupSummary()?  (Read 2335 times)

javidan

  • Junior Woodchuck
  • **
  • Posts: 76

I tried going to the usual place where I look up function documentation http://wiki.jriver.com/index.php/Media_Center_expression_language

It was last updated on on Wed Aug 28 22:20:03 PDT 2013 which appears recent enough to me...but I cannot find the function there.
Logged

MrC

  • Citizen of the Universe
  • *****
  • Posts: 10462
  • Your life is short. Give me your money.

I haven't documented them yet, since they are currently not completely defined or stable.  Search the forums here for GroupCount to find some descriptions.
Logged
The opinions I express represent my own folly.

javidan

  • Junior Woodchuck
  • **
  • Posts: 76

Right, thanks.

I was under the, clearly mistaken, impression that documentation was created automatically when new functions are added like java.  :)
Logged

MrC

  • Citizen of the Universe
  • *****
  • Posts: 10462
  • Your life is short. Give me your money.

Now if only Java were self-correcting in terms of exploits.

No, the function tooltips are built into MC, but not the documentation.  User marko and I have had our hands on the wiki page.
Logged
The opinions I express represent my own folly.

javidan

  • Junior Woodchuck
  • **
  • Posts: 76

No, the function tooltips are built into MC, but not the documentation.  User marko and I have had our hands on the wiki page.

That explains why I learnt most of my scripting from either of you.  ;D

Is there a reason for the page to have the line:
Note: this page was auto-generated on Wed Aug 28 22:20:03 PDT 2013
especially since it is more like a labour of love from two uber JRiver users?
Logged

MrC

  • Citizen of the Universe
  • *****
  • Posts: 10462
  • Your life is short. Give me your money.

I wrote about this in the beta forum.  

The text comes entirely from a very simple text file.  That part is manual, but much easier to write, since I can ignore most wiki and HTML junk.  It looks like below.

I wrote a script to process that text file, to convert it into the wiki you see today.  That's the "auto-generated" stuff.  The code it generates is also below.

Code: [Select]
--------------------------------------------------------------------------------
Section: Accessing and Storing Functions

The functions in this section access field values, store and load global variables,
access file tags, and access note fields.

--------------------------------------------------------------------------------

Function:       Field
Arguments:      name, mode=1
Title:          Returns a field's value
Description:
The FUNCTION function returns the value stored in field name.
The format of return is selected by mode.

Available mode values:
        TABLE_TTb{
0       Raw, unformatted data
1       Formatted data
}

Example:        field(album)
Returns the formatted value of field name "album".
Note that this is equivalent to "[album]".

Example:        field(date, 0)
Returns the raw, unformatted value stored in the "date" field.
Note that this is equivalent to "[date,0]".

--------------------------------------------------------------------------------

Code: [Select]
===Accessing and Storing Functions===

The functions in this section access field values, store and load global variables,
access file tags, and access note fields.
====Field(…): Returns a field's value====

{| style="width: 100%; boarder-spacing: 0; border: 0px solid black;" align="top" cellpadding="3" cellspacing="0"
|- id="Field" valign="top"
! scope="row" style="background: #ecedf3; color: #111; border-style: solid; border-width: 2px 1px 0 2px; border-right: 1px solid #bbb;" width="100" | Description
| style="background: #f9f9f9; color: #111; border-style: solid; border-width: 2px 2px 0 0" width="1200" | <span style="font-family: monospace,monospace; font-size:1em; color:#0f3f8d; font-size:110%"><b>field(</b><i>name</i><b>, </b><i>mode</i><b>)</b></span>
The [[#Field|Field()]] function returns the value stored in field <i>name</i>.
The format of return is selected by <i>mode</i>.

Available <i>mode</i> values:
<div style="margin-left: 20pt;"><table style="border-spacing:0px; border-collapse:collapse; background: #f9f9f9">
<tr><td style="text-align:left; padding-right:20pt"><b>0</b></td><td>Raw, unformatted data</td></tr>
<tr><td style="text-align:left; padding-right:20pt"><b>1</b></td><td>Formatted data</td></tr>
</table></div>

Argument <i>mode</i> is optional (defaults to 1).

|- valign="top"
! scope="row" style="background: #ecedf3; color: #111; border-style: solid; border-width: 0px 1px 2px 2px; border-top: 1px solid #bbb; border-right: 1px solid #bbb;" | Examples
|style="background: #f9f9f9; color: #111; border-style: solid; border-width: 0px 2px 2px 0; border-top: 1px solid #bbb;" | <span style="font-family: monospace,monospace; font-size:1em;"><b><nowiki>field(album)</nowiki></b></span>
<p style="margin-left:20pt;">Returns the formatted value of field <i>name</i> <span style="font-family: monospace,monospace; font-size:1em;">album</span>.
Note that this is equivalent to <span style="font-family: monospace,monospace; font-size:1em;">[album]</span>.</p>
<span style="font-family: monospace,monospace; font-size:1em;"><b><nowiki>field(date, 0)</nowiki></b></span>
<p style="margin-left:20pt;">Returns the raw, unformatted value stored in the <span style="font-family: monospace,monospace; font-size:1em;">date</span> field.
Note that this is equivalent to <span style="font-family: monospace,monospace; font-size:1em;">[date,0]</span>.</p>
|}
<div style="text-align:right;">([[#top|Back to top)]]</div>

All this generates the wiki section you see (see attached).
Logged
The opinions I express represent my own folly.
Pages: [1]   Go Up