Package nds2
Class connection
java.lang.Object
nds2.connection
- All Implemented Interfaces:
Closeable,AutoCloseable
A connection to the NDS/NDS2 server
The connection object is used to interact with the NDS (v1 or v2) servers to retrieve
data and channel lists.
Connnection objects have a few main categories of methods:
1. Data retreival (fetch and iterate)
2. Channel listing (find_channels)
In addition there are methods designed to deal with the volume of data and channels in a NDS2 server:
1. Setting limits/epochs on requests (get_epoch, set_epoch, current_epoch)
2. Channel availability checking (get_availability)
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intprotected boolean -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedconnection(long cPtr, boolean cMemoryOwn) connection(String host) connection(String host, int port) connection(String host, int port, int protocol) connection(parameters params) -
Method Summary
Modifier and TypeMethodDescriptionbooleanvoidclose()longlongcountChannels(String channel_glob) longcountChannels(String channel_glob, int channel_type_mask) longcountChannels(String channel_glob, int channel_type_mask, int data_type_mask) longcountChannels(String channel_glob, int channel_type_mask, int data_type_mask, double min_sample_rate) longcountChannels(String channel_glob, int channel_type_mask, int data_type_mask, double min_sample_rate, double max_sample_rate) voiddelete()buffer[]protected voidfinalize()channel[]channel[]findChannels(String channel_glob) channel[]findChannels(String channel_glob, int channel_type_mask) channel[]findChannels(String channel_glob, int channel_type_mask, int data_type_mask) channel[]findChannels(String channel_glob, int channel_type_mask, int data_type_mask, double min_sample_rate) channel[]findChannels(String channel_glob, int channel_type_mask, int data_type_mask, double min_sample_rate, double max_sample_rate) getAvailability(String[] channel_names) protected static longgetCPtr(connection obj) getHost()getParameter(String parameter) intgetPort()inthash()protected connectioniterate_base(int gps_start, int gps_stop, int stride, String[] channel_names) protected connectioniterate_base(int gps_start, int gps_stop, String[] channel_names) protected connectioniterate_base(int stride, String[] channel_names) protected connectioniterate_base(String[] channel_names) buffer[]next()booleanbooleansetEpoch(int gps_start, int gps_stop) booleanbooleansetParameter(String parameter, String value) voidshutdown()protected static longswigRelease(connection obj)
-
Field Details
-
swigCMemOwn
protected transient boolean swigCMemOwn -
PROTOCOL_INVALID
public static final int PROTOCOL_INVALID -
PROTOCOL_ONE
public static final int PROTOCOL_ONE -
PROTOCOL_TWO
public static final int PROTOCOL_TWO -
PROTOCOL_TRY
public static final int PROTOCOL_TRY -
DEFAULT_PORT
public static final int DEFAULT_PORT -
FAST_STRIDE
public static final int FAST_STRIDE -
AUTO_STRIDE
public static final int AUTO_STRIDE
-
-
Constructor Details
-
connection
protected connection(long cPtr, boolean cMemoryOwn) -
connection
-
connection
-
connection
-
connection
-
connection
public connection()
-
-
Method Details
-
getCPtr
-
swigRelease
-
finalize
protected void finalize() -
delete
public void delete() -
iterate
- Throws:
UnsupportedOperationException
-
iterate
public connection_iterator iterate(int Stride, String[] Channels) throws UnsupportedOperationException - Throws:
UnsupportedOperationException
-
iterate
public connection_iterator iterate(int Start, int Stop, String[] Channels) throws UnsupportedOperationException - Throws:
UnsupportedOperationException
-
iterate
public connection_iterator iterate(int Start, int Stop, int Stride, String[] Channels) throws UnsupportedOperationException - Throws:
UnsupportedOperationException
-
close
public void close()- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable
-
countChannels
public long countChannels(String channel_glob, int channel_type_mask, int data_type_mask, double min_sample_rate, double max_sample_rate) -
countChannels
public long countChannels(String channel_glob, int channel_type_mask, int data_type_mask, double min_sample_rate) -
countChannels
-
countChannels
-
countChannels
-
countChannels
public long countChannels() -
findChannels
-
findChannels
-
findChannels
-
findChannels
-
findChannels
-
findChannels
-
getEpochs
-
setEpoch
-
setEpoch
public boolean setEpoch(int gps_start, int gps_stop) -
currentEpoch
-
check
-
fetch
-
getHost
-
getPort
public int getPort() -
getProtocol
public int getProtocol() -
setParameter
-
getParameter
-
getParameters
-
parameters
-
hash
-
iterate_base
-
iterate_base
-
iterate_base
-
iterate_base
-
next
-
requestInProgress
public boolean requestInProgress() -
shutdown
public void shutdown() -
getAvailability
-