org.das2
Class DasApplication

java.lang.Object
  extended by org.das2.DasApplication

public class DasApplication
extends java.lang.Object

DasApplication object manages per-application resources, like object name space, dataset caching, progress monitoring, exception handling and a network speed limiter.


Method Summary
 javax.swing.JFrame createMainFrame()
          Deprecated. use createMainFrame(String title)
 javax.swing.JFrame createMainFrame(java.awt.Container container)
          Deprecated. use createMainFrame( String title, Container container );
 javax.swing.JFrame createMainFrame(java.lang.String title)
           
 javax.swing.JFrame createMainFrame(java.lang.String title, java.awt.Container container)
           
static java.io.File getDas2UserDirectory()
          returns the location of the local directory sandbox.
 java.lang.String getDas2Version()
           
 DataSetCache getDataSetCache()
           
static DasApplication getDefaultApplication()
           
 ExceptionHandler getExceptionHandler()
           
 InputStreamMeter getInputStreamMeter()
           
 java.util.logging.Logger getLogger()
           
 java.util.logging.Logger getLogger(LoggerId id)
          Deprecated. use DasLogger.getLogger( LoggerId )
 javax.swing.JFrame getMainFrame()
           
 MonitorFactory getMonitorFactory()
           
 NameContext getNameContext()
           
static java.lang.String getProperty(java.lang.String name, java.lang.String deft)
          support restricted security environment by checking permissions before checking property.
static boolean hasAllPermission()
          check the security manager to see if all permissions are allowed, True indicates is not an applet running in a sandbox.
 boolean isApplet()
           
static boolean isHeadAvailable()
           
 boolean isHeadless()
           
 boolean isInteractive()
          Getter for property interactive.
 boolean isReloadLoggingProperties()
           
 void quit()
           
static void resetDefaultApplication()
          nasty, evil method for releasing resources on a server.
 void setApplet(boolean applet)
           
 void setHeadless(boolean headless)
           
 void setInteractive(boolean interactive)
          Setter for property interactive.
 void setReloadLoggingProperties(boolean v)
           
 java.lang.String suggestNameFor(java.lang.Object c)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getLogger

public java.util.logging.Logger getLogger()

getLogger

public java.util.logging.Logger getLogger(LoggerId id)
Deprecated. use DasLogger.getLogger( LoggerId )


getNameContext

public NameContext getNameContext()

suggestNameFor

public java.lang.String suggestNameFor(java.lang.Object c)

getDefaultApplication

public static DasApplication getDefaultApplication()

resetDefaultApplication

public static void resetDefaultApplication()
nasty, evil method for releasing resources on a server. DO NOT USE THIS!!!!


isApplet

public final boolean isApplet()

hasAllPermission

public static boolean hasAllPermission()
check the security manager to see if all permissions are allowed, True indicates is not an applet running in a sandbox.

Returns:
true if all permissions are allowed

getProperty

public static java.lang.String getProperty(java.lang.String name,
                                           java.lang.String deft)
support restricted security environment by checking permissions before checking property.

Parameters:
name -
deft -
Returns:

setApplet

public void setApplet(boolean applet)

setReloadLoggingProperties

public void setReloadLoggingProperties(boolean v)

isReloadLoggingProperties

public boolean isReloadLoggingProperties()

getDas2UserDirectory

public static java.io.File getDas2UserDirectory()
returns the location of the local directory sandbox. For example, The web filesystem object downloads temporary files to here, logging properties file, etc. Assume that this File is local, so I/O is quick, and that the process has write access to this area. For definition, assume that at least 1Gb of storage is available as well.


isHeadAvailable

public static boolean isHeadAvailable()

isHeadless

public boolean isHeadless()

setHeadless

public void setHeadless(boolean headless)

getInputStreamMeter

public InputStreamMeter getInputStreamMeter()

createMainFrame

public javax.swing.JFrame createMainFrame(java.awt.Container container)
Deprecated. use createMainFrame( String title, Container container );


createMainFrame

public javax.swing.JFrame createMainFrame(java.lang.String title,
                                          java.awt.Container container)

createMainFrame

public javax.swing.JFrame createMainFrame()
Deprecated. use createMainFrame(String title)


createMainFrame

public javax.swing.JFrame createMainFrame(java.lang.String title)

getMainFrame

public javax.swing.JFrame getMainFrame()

quit

public void quit()

isInteractive

public boolean isInteractive()
Getter for property interactive.

Returns:
Value of property interactive.

setInteractive

public void setInteractive(boolean interactive)
Setter for property interactive.

Parameters:
interactive - New value of property interactive.

getDas2Version

public java.lang.String getDas2Version()

getMonitorFactory

public MonitorFactory getMonitorFactory()

getDataSetCache

public DataSetCache getDataSetCache()

getExceptionHandler

public ExceptionHandler getExceptionHandler()