Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

org.dbtutools.DbtuTools.core.db2
Class Instance  view Instance download Instance.java

java.lang.Object
  extended byorg.dbtutools.DbtuTools.core.db2.Instance

public class Instance
extends java.lang.Object

Wrapper class, implementing DB2 Instance related stuff.


Field Summary
protected  java.lang.String oInstanceName
          Field holding the name of the DB2 instance, which is addressed by the instance of this class.
 
Constructor Summary
Instance()
          Creates a new instance of this class and addressed the current DB2 Instance.

Background: This constructor calls a private method which interprets the value returned by java.lang.System.getProperty("DB2INSTANCE");
Instance(java.lang.String oInstanceName)
          Creates a new instance of this class - addressing the provided DB2 Instance name.

Remark: Please notice, the constructor does not check for the existence of the given DB2 instance!
 
Method Summary
static Instance getInstance()
          Creates and returns an instance of this class which addresses the current DB2 Instance.
 java.lang.String getInstanceName()
          Returns the DB2 Instance name (from the oInstanceName 55 field).
private  void setInstanceNameByEnvironment()
          As the method name says, this method reads the name of the DB2 Instance from the environment and sets the oInstanceName 55 field.

Background: The detection is done by interpreting the value of java.lang.System.getProperty("DB2INSTANCE");
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

oInstanceName

protected java.lang.String oInstanceName
Field holding the name of the DB2 instance, which is addressed by the instance of this class. ************************************************************************

Constructor Detail

Instance

public Instance()
         throws org.edelbyte.util.UnknownValueException
Creates a new instance of this class and addressed the current DB2 Instance.

Background: This constructor calls a private method which interprets the value returned by java.lang.System.getProperty("DB2INSTANCE");


Instance

public Instance(java.lang.String oInstanceName)
         throws java.lang.NullPointerException
Creates a new instance of this class - addressing the provided DB2 Instance name.

Remark: Please notice, the constructor does not check for the existence of the given DB2 instance!

Method Detail

getInstance

public static Instance getInstance()
                            throws org.edelbyte.util.UnknownValueException
Creates and returns an instance of this class which addresses the current DB2 Instance.


getInstanceName

public java.lang.String getInstanceName()
Returns the DB2 Instance name (from the oInstanceName 55 field).


setInstanceNameByEnvironment

private void setInstanceNameByEnvironment()
                                   throws org.edelbyte.util.UnknownValueException
As the method name says, this method reads the name of the DB2 Instance from the environment and sets the oInstanceName 55 field.

Background: The detection is done by interpreting the value of java.lang.System.getProperty("DB2INSTANCE");