Yeah, get(). I corrected my comment after I noticed that it didn't line 
up properly with what I selected, but the correction may not get sent 
out via email. Sorry for the confusion.

I meant to implement a getInstance() static method and a private 
constructor to ensure that only one preferences model is ever created. 
getInstance() would return a reference to a private static 
PreferencesModel variable named instance, and would instantiate that if 
necessary. This is the singleton pattern.

It's no big deal, though. I approved it since this meets all standards.

The sets in the constructor are totally fine - stupid github interface 
included way too many lines in my comment :)

Regards,
Chris


On 3/23/2014 1:39 PM, Ethan Schwartz wrote:
>
> In bubolo/src/bubolo/ui/Preferences/PreferencesModel.java:
>
> > +	 * Constructor will create a new PreferencesModel object with default values
> > +	 *
> > +	 * @author BU CS673 - Clone Productions
> > +	 */
> > +	public PreferencesModel()
> > +	{
> > +		setSfxVol(UserInterface.SFXVOL_DEFAULT);
> > +		setMfxVol(UserInterface.MFXVOL_DEFAULT);
> > +		setScreenSize(UserInterface.SCREENSIZE_DEFAULT);
> > +	}
> > +	
> > +	/**
> > +	 * This get will return the current Preferences Model
> > +	 * @return returns this object
> > +	 */
> > +	public PreferencesModel get()
> Hi Chris, You mean get()? ... or you mean why am I using the set's in 
> the constructor? I put the get in because we had talked about having a 
> method for the PreferencesModel that would return a PreferenceModel... 
> but what I have put may actually be ridiculous in the end :) As for 
> the set's in the constructor, I am trying t use the UserInterface 
> class as a holder for common setting in the UI and other defaults so 
> that there is a central place to see them all--this might not be a 
> standard way to do it, if it's not I can change?
> … <#>
> Sadly a bit of a learning process for me--I've already realized that I 
> probably should have created a BoloJFrame class to extend JFrame and 
> then used that as a basis for other frames. I'm also looking into a 
> better way to handle the buttons--apparently there is an Action class 
> that you can pass into the JButton at creation that may simplify a lot 
> of my code. I'm looking at implementing a UI for setting the controls 
> (I put in a new issue for that this morning), for that one we'll have 
> a lot of buttons, so I want to find a way to make the UI code very 
> simple and build up the UI programmatically from some sort of a list 
> (where-as now I'm constructing it line by line, and I have to have 
> special methods to handle each ActionListener, etc). This would be for 
> Sprint 3.
> -Ethan
> On Sun, Mar 23, 2014 at 1:26 PM, Christopher D Canfield < 
> notifications@github.com> wrote: In 
> bubolo/src/bubolo/ui/Preferences/PreferencesModel.java: > + * 
> Constructor will create a new PreferencesModel object with default 
> values > + * > + * @author <https://github.com/author> BU CS673 - 
> Clone Productions > + */ > + public PreferencesModel() > + { > + 
> setSfxVol(UserInterface.SFXVOL_DEFAULT); > + 
> setMfxVol(UserInterface.MFXVOL_DEFAULT); > + 
> setScreenSize(UserInterface.SCREENSIZE_DEFAULT); > + } > + > + /** > + 
> * This get will return the current Preferences Model > + * @return 
> <https://github.com/return> returns this object > + */ > + public 
> PreferencesModel get() Out of curiosity, what is this method used for? 
> -- Reply to this email directly or view it on 
> GitHub<https://github.com/BU-CS673/bubolo/pull/202/files#r10868162> .
>
> —
> Reply to this email directly or view it on GitHub 
> <https://github.com/BU-CS673/bubolo/pull/202/files#r10868230>.
>