Code Search for Developers
 
 
  

FloatTextBoxWithID.java from MASE: Agile Software Engineering at Krugle


Show FloatTextBoxWithID.java syntax highlighted

package ucalgary.ebe.webui.client.ui;

public class FloatTextBoxWithID extends TextBoxWithID {
	
	private boolean changed = false;
	private float value;
	
	private static final String FLOAT_PATTERN = "\\d+(\\.{1}\\d+)?";

	public FloatTextBoxWithID(long id, float value) {
		super(id);
		setText(String.valueOf(value));
	}
	
	public void setText(String f) {
		if(f.matches(FLOAT_PATTERN)) {
			super.setText(f);
			this.changed = true;
			this.value = Float.valueOf(f).floatValue();
			this.content = f;
		} else {
			this.changed = false;
			super.setText(this.content);
		}
	}
	
	public boolean hasChanged() {
		return this.changed;
	}
	
	public float getValue() {
		return this.value;
	}

}




See more files for this project here

MASE: Agile Software Engineering

The MASE project investigates methods to support the coordination and executable acceptance testing of software projects. Keywords: Agile methods, distributed teams, Extreme Programming. See http://ebe.cpsc.ucalgary.ca/ebe for more information.

Project homepage: http://sourceforge.net/projects/mase
Programming language(s): Java,XML
License: other

  CreateIterationDialogBox.java
  CreateProjectDialogBox.java
  CreateStoryCardDialogBox.java
  FloatTextBoxWithID.java
  ImageWithID.java
  ProjectListBox.java
  ProjectWhiteBoard.java
  StoryCardGrid.java
  StoryCardParentListBox.java
  TextBoxWithID.java
  TimestampTextBoxWithID.java
  WebUIMenu.java