com.raben.telescope.comm
Class TelescopeFactory

java.lang.Object
  |
  +--com.raben.telescope.comm.TelescopeFactory

public class TelescopeFactory
extends java.lang.Object

Factory for creating instance of a concrete implementation of the TelescopeInterface

Version:
$Revision: 1.3 $ $Date: 2003/09/11 15:14:40 $
Author:
Vern Raben

Method Summary
static TelescopeInterface getInstance(java.lang.String modelName)
          Get instance of TelescopeInterface for specified modelName
static TelescopeInterface getInstance(TelescopeModel model)
          Get instance of TelescopeInterface for specified telescope model
static java.util.Properties loadProperties()
          Load properties file if it exists
static TelescopeInterface newInstance()
          Create instance of TelescopeInterface for telescope model that has been stored in a properties file.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

newInstance

public static TelescopeInterface newInstance()
Create instance of TelescopeInterface for telescope model that has been stored in a properties file. If properties file doesn't exist the default will be a Celestron Nextar GPS

Returns:
TelescopeInterface

getInstance

public static TelescopeInterface getInstance(java.lang.String modelName)
Get instance of TelescopeInterface for specified modelName

Parameters:
modelName - Name of telescope model @see TelescopeModel
Returns:
TelescopeInterface - May return null if modelName is incorrect

getInstance

public static TelescopeInterface getInstance(TelescopeModel model)
Get instance of TelescopeInterface for specified telescope model

Parameters:
model - of telescope
Returns:
TelescopeInterface

loadProperties

public static java.util.Properties loadProperties()
Load properties file if it exists

Returns:
Properties Telescope propertis


Copyright © 2003 Raben Systems, Inc.. All Rights Reserved.