dods.dap.Server
Class ServerDDS

java.lang.Object
  extended by dods.dap.DDS
      extended by dods.dap.Server.ServerDDS
All Implemented Interfaces:
Cloneable

public class ServerDDS
extends dods.dap.DDS
implements Cloneable

ServerDDS is a specialization of DDS for the server-side of DODS. This class includes methods used to distinguish synthesized variables (variables added to the DDS by a constraint expression function), methods for CE function management and methods used to return a `constrained DDS' as part of a DODS data document.

All of the variables contained by a ServerDDS must implement the Projection interface.

Version:
$Revision: 1.3 $
Author:
jhrg
See Also:
DDS, CEEvaluator

Field Summary
 
Fields inherited from class dods.dap.DDS
name, vars
 
Constructor Summary
protected ServerDDS()
           
  ServerDDS(dods.dap.BaseTypeFactory factory)
          Creates an empty ServerDDS with the given BaseTypeFactory.
protected ServerDDS(String n)
          Creates an empty Server DDS with the given dataset name.
  ServerDDS(String n, dods.dap.BaseTypeFactory factory)
          Creates an empty ServerDDS with the given dataset name and BaseTypeFactory.
 
Method Summary
 Object clone()
          Return a clone of the ServerDDS.
 String getDatasetFilename()
          Get the dataset filename.
 void printConstrained(OutputStream os)
          Print the constrained DDS on the given OutputStream.
 void printConstrained(PrintWriter os)
          Print the constrained DDS on the given PrintWriter.
 void setDatasetFilename(String n)
          Set the filename of the dataset.
 
Methods inherited from class dods.dap.DDS
addVariable, checkSemantics, checkSemantics, delVariable, getFactory, getName, getVariable, getVariables, numVariables, parse, print, print, search, setName
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ServerDDS

protected ServerDDS()

ServerDDS

protected ServerDDS(String n)
Creates an empty Server DDS with the given dataset name.

Parameters:
n - the dataset name

ServerDDS

public ServerDDS(dods.dap.BaseTypeFactory factory)
Creates an empty ServerDDS with the given BaseTypeFactory. This will be used for DODS servers which need to construct subclasses of the various BaseType objects to hold additional server-side information.

Parameters:
factory - the server BaseTypeFactory object.

ServerDDS

public ServerDDS(String n,
                 dods.dap.BaseTypeFactory factory)
Creates an empty ServerDDS with the given dataset name and BaseTypeFactory. This will be used for DODS servers which need to construct subclasses of the various BaseType objects to hold additional server-side information.

Parameters:
n - the dataset name
factory - the server BaseTypeFactory object.
Method Detail

clone

public Object clone()
Return a clone of the ServerDDS. A deep copy is performed on this object and those it contains.

Overrides:
clone in class dods.dap.DDS
Returns:
a ServerDDS object.

setDatasetFilename

public void setDatasetFilename(String n)
Set the filename of the dataset. This must be passed to the read() method of the FileIO interface. The filename of the dataset may be a real filename or may be any other string that can be used to identify for the read method how to access the data-store of which a particular variable is a member.

Parameters:
n - The name of the dataset.
See Also:
ServerMethods.read()

getDatasetFilename

public String getDatasetFilename()
Get the dataset filename.

Returns:
The filename of the dataset.
See Also:
setDatasetFilename(String)

printConstrained

public void printConstrained(PrintWriter os)
Print the constrained DDS on the given PrintWriter.

Parameters:
os - the PrintWriter to use for output.

printConstrained

public final void printConstrained(OutputStream os)
Print the constrained DDS on the given OutputStream.

Parameters:
os - the OutputStream to use for output.
See Also:
DDS.print(PrintWriter)