com.partnersoft.v3x.apps.Staker.FieldStaker
Class Staker

java.lang.Object
  extended by com.partnersoft.v3x.apps.Staker.FieldStaker.Staker

public class Staker
extends java.lang.Object

The lovely and oh-so-functional Staking Partner Field Staking Unit.


Field Summary
 ControlPanel controls
          The control panel.
 
Constructor Summary
Staker(MapApp mapApp, MapSet mapSet)
          Create new staker.
 
Method Summary
 void addStakerListener(StakerListener listener)
           
 void applyPostprocessingCorrections()
           
static void clearSingleton()
           
 void clearViewedJobs()
           
 void convertToLocation(java.lang.Object selected)
          This is the Convert To Location function.
 void convertToStation(java.lang.Object selected)
          This is the Convert To Station function.
 void convertToStation(java.lang.Object selected, boolean noDialog)
           
static Staker createHeadlessStaker(MapApp mapApp, MapSet mapSet)
           
 void createOnTheFlyImages(MapApp app)
           
 void decrementBusiness()
           
 void deleteLocation()
           
 void editLocation()
           
 void exit()
           
 void fireJobChanged()
           
 void generateReports()
          Generates the staking sheet and other reports for the current job.
 void generateReportsFor(Job jobbo)
           
 java.util.ArrayList getAttachedFileNames(Job job)
           
 StakerConfiguration getConfiguration()
          Gets the configuration for the staker.
 ControlPanel getControlPanel()
           
 javax.swing.JFileChooser getFileChooser()
           
static Staker getInstance()
           
 Job getJob()
          Gets current job.
static java.util.ArrayList getLineDataTypes()
           
 LocationEditor getLocationEditor()
           
 StakerLogic getLogic()
           
 MapApp getMapApp()
           
 java.util.Map getMapCopyDataTypes()
           
 MapSet getMapSet()
           
static java.util.ArrayList getPointDataTypes()
           
 StakerPreferences getPreferences()
          Gets the preferences.
 java.util.Map getSelectedMapData()
           
 StakingNode getSelectedNode()
           
 double getSelectedX()
           
 double getSelectedY()
           
 StakingBuddyJob getStakingBuddyJob()
           
 java.util.ArrayList<java.lang.Object> getStakingBuddyJobs()
           
 JobNodeSpecifier getStakingSpecifier()
           
 java.util.List<Job> getViewedJobs()
           
 java.awt.Window getWindow()
           
 void help()
           
 void incrementBusiness()
           
 void initializeImp(PropMap args)
           
 boolean isHeadless()
           
 void loadMapCopyDataTypes()
           
 void loadPreferences()
           
 void moveStakingBuddyPoints(double offsetX, double offsetY)
           
 void noSaveAndExit()
           
 void refreshJob()
          Currently the staking space is differently from the job; this is unfortunate because it causes some normalization problems.
 void removeStakerListener(StakerListener listener)
           
 void saveAndExit()
           
 void savePreferences()
           
 void setConfiguration(StakerConfiguration newConfig)
          Sets the configuration for the staker.
 void setJob(Job newJob)
          Sets current job.
 void setJob(Job newJob, boolean doNotRecenter)
          Sets current job.
 void setMapCopyDataTypes(java.util.Map dataTypes)
           
 void setSelectedNode(StakingNode node)
           
 void setStakingBuddyJob(StakingBuddyJob sbj)
           
 void setStakingBuddyJobs(java.util.ArrayList<java.lang.Object> sbjs)
           
static Staker singleton(MapApp mapApp, MapSet mapSet)
           
 void viewJob(Job viewMe)
          Views a job.
 void viewJobs(java.util.ArrayList<Job> jobs)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

controls

public ControlPanel controls
The control panel.

Constructor Detail

Staker

public Staker(MapApp mapApp,
              MapSet mapSet)
Create new staker.

Method Detail

getInstance

public static Staker getInstance()

singleton

public static Staker singleton(MapApp mapApp,
                               MapSet mapSet)
                        throws java.lang.Exception
Throws:
java.lang.Exception

clearSingleton

public static void clearSingleton()

createHeadlessStaker

public static Staker createHeadlessStaker(MapApp mapApp,
                                          MapSet mapSet)

getPointDataTypes

public static java.util.ArrayList getPointDataTypes()

getLineDataTypes

public static java.util.ArrayList getLineDataTypes()

generateReportsFor

public void generateReportsFor(Job jobbo)

initializeImp

public void initializeImp(PropMap args)
                   throws java.lang.Exception
Throws:
java.lang.Exception

getFileChooser

public javax.swing.JFileChooser getFileChooser()

getWindow

public java.awt.Window getWindow()

getJob

public Job getJob()
Gets current job.


setJob

public void setJob(Job newJob)
Sets current job.


setJob

public void setJob(Job newJob,
                   boolean doNotRecenter)
Sets current job. If doNotRecenter is true, does not move the view to display the job.


fireJobChanged

public void fireJobChanged()

loadMapCopyDataTypes

public void loadMapCopyDataTypes()

getMapCopyDataTypes

public java.util.Map getMapCopyDataTypes()

setMapCopyDataTypes

public void setMapCopyDataTypes(java.util.Map dataTypes)

getStakingBuddyJob

public StakingBuddyJob getStakingBuddyJob()

setStakingBuddyJob

public void setStakingBuddyJob(StakingBuddyJob sbj)

getStakingBuddyJobs

public java.util.ArrayList<java.lang.Object> getStakingBuddyJobs()

setStakingBuddyJobs

public void setStakingBuddyJobs(java.util.ArrayList<java.lang.Object> sbjs)

moveStakingBuddyPoints

public void moveStakingBuddyPoints(double offsetX,
                                   double offsetY)

viewJob

public void viewJob(Job viewMe)
Views a job. All viewed jobs are purged when a job is closed.


viewJobs

public void viewJobs(java.util.ArrayList<Job> jobs)

clearViewedJobs

public void clearViewedJobs()

getConfiguration

public StakerConfiguration getConfiguration()
Gets the configuration for the staker.


setConfiguration

public void setConfiguration(StakerConfiguration newConfig)
Sets the configuration for the staker.


getPreferences

public StakerPreferences getPreferences()
Gets the preferences.


getSelectedMapData

public java.util.Map getSelectedMapData()

getSelectedX

public double getSelectedX()

getSelectedY

public double getSelectedY()

isHeadless

public boolean isHeadless()

refreshJob

public void refreshJob()
Currently the staking space is differently from the job; this is unfortunate because it causes some normalization problems. Run this method before doing any calculations based on staking nodes or saving the job or anything; it reflects changes made on the map back into the job. Now it handles snapshots, too. Dammit.


exit

public void exit()

noSaveAndExit

public void noSaveAndExit()

saveAndExit

public void saveAndExit()

incrementBusiness

public void incrementBusiness()

decrementBusiness

public void decrementBusiness()

loadPreferences

public void loadPreferences()

savePreferences

public void savePreferences()

generateReports

public void generateReports()
Generates the staking sheet and other reports for the current job.


addStakerListener

public void addStakerListener(StakerListener listener)

removeStakerListener

public void removeStakerListener(StakerListener listener)

help

public void help()

deleteLocation

public void deleteLocation()

editLocation

public void editLocation()

convertToStation

public void convertToStation(java.lang.Object selected)
This is the Convert To Station function. This function converts a location into a valid Station.


convertToStation

public void convertToStation(java.lang.Object selected,
                             boolean noDialog)

convertToLocation

public void convertToLocation(java.lang.Object selected)
This is the Convert To Location function. This function converts a station into a valid Location.


getControlPanel

public ControlPanel getControlPanel()

getMapApp

public MapApp getMapApp()

getMapSet

public MapSet getMapSet()

getStakingSpecifier

public JobNodeSpecifier getStakingSpecifier()

getLogic

public StakerLogic getLogic()

getSelectedNode

public StakingNode getSelectedNode()

setSelectedNode

public void setSelectedNode(StakingNode node)

getLocationEditor

public LocationEditor getLocationEditor()

getViewedJobs

public java.util.List<Job> getViewedJobs()

applyPostprocessingCorrections

public void applyPostprocessingCorrections()

createOnTheFlyImages

public void createOnTheFlyImages(MapApp app)

getAttachedFileNames

public java.util.ArrayList getAttachedFileNames(Job job)