## org.autoplot.datasource.DataSource

Like the DataLoader of das2, but provides minimal dataset discovery metadata

## asynchronousLoad

asynchronousLoad( ) → boolean

loading the data is slow, so load the data asynchronously (on a separate thread). This should return true if getDataSet will take more than 100 milliseconds (interactive time). Note this is currently ignored, and may be indefinitely ignored.

### Returns:

boolean
[search for examples] [view on GitHub] [view on old javadoc] [view source]

## getCapability

getCapability( java.lang.Class clazz ) → Object

cookie jar of capabilities, see org.autoplot.datasource.capability. Each capability can be queried, and either an object implementing the capability or null is returned. Example capabilities include:

TimeSeriesBrowse | which allows the user to request data from a different interval.
Caching | which should be queried before the loader is called again.

Note the DataSourceFactory also has a getCapability method, solely to provide TimeSeriesBrowse so that new URIs can be created in without reading data.

### Parameters

clazz - a java.lang.Class

### Returns:

java.lang.Object
[search for examples] [view on GitHub] [view on old javadoc] [view source]

## getDataSet

getDataSet( ProgressMonitor mon ) → QDataSet

retrieve the dataset. This allowed to be sub-interactive or batch time scale, and will block until the dataset is produced. This may return null when no data is available, or NoDataInIntervalException can be thrown. If the user cancelled the operation, then java.io.InterrupedIOExcaption or better yet org.das2.CancelledOperationException should be called. These will simply display "cancelled" (or similar) on the status bar.

### Parameters

mon - a ProgressMonitor

### Returns:

the DataSet for the URI, or null if no data is available.
[search for examples] [view on GitHub] [view on old javadoc] [view source]

## getMetadata

getMetadata( ProgressMonitor mon ) → java.util.Map

Return arbitrary metadata for the dataset. This is a map of String to Objects, and to form a tree structure, property name may map to another Map<String,Object>. Note the order of the properties may be controlled by using LinkedHashMap for the implementation. Even though this takes a monitor, it will be called after getDataSet, and the monitor may be safely ignored. This should return new HashMap() if no metadata is found.

### Parameters

mon - a ProgressMonitor

### Returns:

a java.util.Map
[search for examples] [view on GitHub] [view on old javadoc] [view source]

## getMetadataModel

getMetadataModel( ) → org.autoplot.datasource.MetadataModel

return a MetadataModel that scrapes the Metadata tree returned to provide a set of properties identified in QDataSet.

### Returns:

an org.autoplot.datasource.MetadataModel
[search for examples] [view on GitHub] [view on old javadoc] [view source]

## getProperties

getProperties( ) → java.util.Map

discovery properties for the dataset. These should follow the QDataSet conventions, such as TITLE, LABEL, etc, and should mirror the structure of the dataset. Note getMetadataModel().getProperties( getMetaData() ) should return the same thing.

### Returns:

the properties.
[search for examples] [view on GitHub] [view on old javadoc] [view source]

## getURI

getURI( ) → String

return the fully-qualified URI of this data source, including the "vap+:" scheme.

### Returns:

a String
[search for examples] [view on GitHub] [view on old javadoc] [view source]