Class SNTLinkHandler
- All Implemented Interfaces:
Comparable<org.scijava.Prioritized>,org.scijava.Contextual,org.scijava.desktop.links.LinkHandler,org.scijava.Identifiable,org.scijava.Locatable,org.scijava.log.Logged,org.scijava.plugin.HandlerPlugin<URI>,org.scijava.plugin.HasPluginInfo,org.scijava.plugin.RichPlugin,org.scijava.plugin.SciJavaPlugin,org.scijava.plugin.SingletonPlugin,org.scijava.plugin.TypedPlugin<URI>,org.scijava.Prioritized,org.scijava.Typed<URI>,org.scijava.Versioned
snt:// links, allowing SNT to be launched (or driven) from outside Fiji, e.g., from a browser, a
paper's supplementary HTML, or another SciJava application, via scijava-desktop's LinkHandler mechanism.
The canonical form is fiji://snt/<operation>?<parameters>, which works on all platforms.
snt://<operation>?<parameters> is also accepted where the OS allows registering it (see Links).
Parameter values must be percent-encoded. Images and tracings must be given as URLs or as absolute local paths/
file: URIs (local ones only work on the machine hosting them).
Operations:
open (default) Opens image (SNT Stream for streamed data), loads tracings and flies to view. If image is already
open, only the latter two are applied
fly As open, but view is mandatory
demo Loads a demo (see id), or a demo reconstruction (see tree)
Parameters of open/fly:
image URL, path, file: URI, or demo:name for a bundled image (as in SNTService#initialize(String, boolean)).
If omitted, acts on what is open
stream true|false. Inferred from image (.zarr, .n5, .ims, .xml, s3:, gs: mean stream)
viewer bvv (default)|bdv. Streamed launches only
tracer true (default)|false. false opens a plain viewer with no SNT session. Streamed launches only
tracings URL, path, file: URI, or demo:name for a bundled reconstruction. Streamed launches also accept a folder
or .zip archive (but not demos). Not loaded into an already-open
standalone viewer
mode add (default)|replace. Whether tracings replace existing paths (TRACES files always do). Ignored when
launching a stream
view x,y,z[,t]: world coordinates and optional 1-based timepoint. ig viewers only (ignored by traditional
launches)
Parameters of demo:
id Stable id of a DemoRunner scenario, e.g., 4 (image, tracings, notes, etc.). Takes precedence over tree
tree Name of a bundled reconstruction (default: AA0001)
Examples:
fiji://snt/open?image=https%3A%2F%2Fhost%2Fdata.ome.zarr&view=82.9,-239,-65 fiji://snt/open?image=file%3A%2F%2F%2FUsers%2Fme%2Fimg.tif fiji://snt/open?tracings=https%3A%2F%2Fhost%2Frec.swc&mode=replace fiji://snt/fly?view=10,20,30,2 fiji://snt/open?image=demo:OP1&tracings=demo:OP1 fiji://snt/demo?id=4 fiji://snt/demo?tree=OP_1
NB: channel and ui are not supported yet, and are ignored
Links are pre-flighted against the current state of SNT (see
SNTLink#preflight) before anything is changed. view (world
coordinates, optionally followed by a 1-based timepoint) is only supported
in SNT Stream/big viewers. Streamed links launch SNT Stream (see
BigDataLoaderCmd.open(java.lang.String, java.lang.String, boolean, boolean)), closing a conflicting session first.
NB: handle(URI) may be called off the EDT (e.g., by
LinkArgument while processing command-line/launch arguments), so all
SNT/UI calls are marshaled onto the EDT.
- Author:
- Tiago Ferreira
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Methods inherited from class org.scijava.plugin.AbstractRichPlugin
getInfo, getPriority, setInfo, setPriority, toStringMethods inherited from class org.scijava.AbstractContextual
context, getContextMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.scijava.Contextual
context, getContext, setContextMethods inherited from interface org.scijava.plugin.HasPluginInfo
getInfo, setInfoMethods inherited from interface org.scijava.desktop.links.LinkHandler
getTypeMethods inherited from interface org.scijava.Locatable
getLocationMethods inherited from interface org.scijava.Prioritized
compareTo, getPriority, setPriorityMethods inherited from interface org.scijava.plugin.RichPlugin
getIdentifier, logMethods inherited from interface org.scijava.Versioned
getVersion
-
Field Details
-
SCHEME
The URI scheme handled by this plugin.- See Also:
-
-
Constructor Details
-
SNTLinkHandler
public SNTLinkHandler()
-
-
Method Details