org.biojava.spice.das
Class SpiceDasSource

java.lang.Object
  extended byDas1Source
      extended byorg.biojava.spice.das.SpiceDasSource

public class SpiceDasSource
extends Das1Source

Manages all data about a DAS source that SPICE requires

See Also:
Serialized Form

Field Summary
static String DEFAULT_CAPABILITY
           
static String DEFAULT_NICKNAME
           
 String displayType
           
 boolean unlimitedFeatures
           
 
Constructor Summary
SpiceDasSource()
           
 
Method Summary
static SpiceDasSource fromDasSource(DasSource ds)
          convert DasSource to SpiceDasSource
 Map[] get3DStylesheet()
          get the stylesheet containing the instructions how to paint in 3D.
 String getDisplayType()
           
 boolean getRegistered()
           
 boolean getStatus()
           
 Map[] getStylesheet()
          returns the Stylesheet that is provided by a DAS source.
 boolean hasUnlimitedFeatures()
           
 void loadStylesheet()
           
 void setDisplayType(String displayType)
           
 void setRegistered(boolean flag)
           
 void setStatus(boolean flag)
          a flag if this das source is active or
 void setUnlimitedFeatures(boolean unlimitedFeatures)
           
 String toString()
           
 XMLWriter toXML(XMLWriter xw)
          convert to XML.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

DEFAULT_NICKNAME

public static String DEFAULT_NICKNAME

DEFAULT_CAPABILITY

public static String DEFAULT_CAPABILITY

displayType

public String displayType

unlimitedFeatures

public boolean unlimitedFeatures
Constructor Detail

SpiceDasSource

public SpiceDasSource()
Method Detail

hasUnlimitedFeatures

public boolean hasUnlimitedFeatures()

setUnlimitedFeatures

public void setUnlimitedFeatures(boolean unlimitedFeatures)

getDisplayType

public String getDisplayType()

setDisplayType

public void setDisplayType(String displayType)

loadStylesheet

public void loadStylesheet()

getStylesheet

public Map[] getStylesheet()
returns the Stylesheet that is provided by a DAS source. It provides info of how to draw a particular feature. returns null if not attempt has been made to load the stylesheet. afterwards it returns a Map[0] or the Map[] containing the style data.

Returns:
Map containing the stylesheet

get3DStylesheet

public Map[] get3DStylesheet()
get the stylesheet containing the instructions how to paint in 3D.

Returns:
a Map containing the stylesheet information

setStatus

public void setStatus(boolean flag)
a flag if this das source is active or

Parameters:
flag -

getStatus

public boolean getStatus()

setRegistered

public void setRegistered(boolean flag)

getRegistered

public boolean getRegistered()

fromDasSource

public static SpiceDasSource fromDasSource(DasSource ds)
convert DasSource to SpiceDasSource

Parameters:
ds - a DasSource to be converted
Returns:
a new SpiceDasSource object

toString

public String toString()

toXML

public XMLWriter toXML(XMLWriter xw)
                throws IOException
convert to XML.

Parameters:
xw - an XMLWriter to write to
Returns:
XMLWriter returns it again
Throws:
IOException