Image-DS9

 view release on metacpan or  search on metacpan

ds9-interface.html  view on Meta::CPAN

<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
	"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">

<head>
<title>ds9-interface.html</title>
<meta http-equiv="Content-Type" content="text/html;charset=utf-8"/>

</head>

<body>

<h1>Language agnostic encoding of the DS9 client API</h1>

<h2>RPC Transport protocols</h2>

<p>DS9 supports two RPC transport protocols: XPA and SAMP.  XPA is
supported via a C library or via executable programs.</p>

<h2>Command Syntax</h2>

<p>The native ds9 API resembles most a free-formatted string based
command line interface.  The syntax takes the following form</p>

<blockquote>
<pre><code>command [&lt;subcommand&gt;] [&lt;arguments&gt;]
</code></pre>
</blockquote>

<p>A subcommand may consist of multiple tokens, e.g.the <code>regions</code> command
has a <code>load all</code> subcommand.</p>

<p>Arguments are typically positional, but some commands may use named arguments.
Positional arguments may be variable or constants, e.g. in the <code>regions</code> command</p>

<blockquote>
  <p>regions template foo.tpl at 13:29:55.92 +47:12:48.02 fk5</p>
</blockquote>

<p>The token <code>at</code> is a constant string, while <code>foo.tpl</code>, <code>13:29:55.92</code>,
<code>+47:12:48.02</code>, and <code>fk5</code> are variable.</p>

<p>Named arguments consist of <em>name - value</em> pairs with no required order
between the arguments.  For example,</p>

<blockquote>
<pre><code>regions -format ds9 -system wcs -sky fk5 -skyformat sexagesimal -prop edit 1 -group foo
</code></pre>
</blockquote>

<p>In some cases, the named arguments are embedded in a single token,
e.g. for the <code>array</code> command,</p>

<blockquote>
<pre><code>array foo.arr[dim=512,bitpix=-32,endian=little]
</code></pre>
</blockquote>

<p>Some named arguments exclude others and require others. For example,
the <code>array</code> command's <code>xdim</code> and <code>ydim</code> arguments must appear together, but must not appear with <code>dims</code>.</p>



( run in 1.756 second using v1.01-cache-2.11-cpan-364913b4093 )