se.liu.ida.critiquer.activities.parameters
Class LocationParameter

java.lang.Object
  extended by se.liu.ida.critiquer.activities.parameters.ActivityParameter<Location>
      extended by se.liu.ida.critiquer.activities.parameters.LocationParameter
All Implemented Interfaces:
Serializable, GeoViewParameter, Parameter<Location>

public class LocationParameter
extends ActivityParameter<Location>
implements GeoViewParameter

See Also:
Serialized Form

Nested Class Summary
static class LocationParameter.Type
           
 
Field Summary
 
Fields inherited from class se.liu.ida.critiquer.activities.parameters.ActivityParameter
hasBeenSet, name, oldValue, value, valueUpdate
 
Constructor Summary
LocationParameter(LocationParameter.Type type, String name, Activity a)
           
 
Method Summary
 LocationParameter.Type getType()
           
 boolean setValue(Location newValue)
          Update the value of this parameter iff the value is consistent for this parameter The updating is performed with a binary semaphore set so that there can be no more than one thread updating and signalling activities of a value update
 String toString()
           
 
Methods inherited from class se.liu.ida.critiquer.activities.parameters.ActivityParameter
getActivity, getName, getOldValue, getValue, hasValue, setName, setValue, valueChanged
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

LocationParameter

public LocationParameter(LocationParameter.Type type,
                         String name,
                         Activity a)
Method Detail

setValue

public boolean setValue(Location newValue)
Description copied from class: ActivityParameter
Update the value of this parameter iff the value is consistent for this parameter The updating is performed with a binary semaphore set so that there can be no more than one thread updating and signalling activities of a value update

Overrides:
setValue in class ActivityParameter<Location>
Parameters:
newValue - The value to set. Sets a value and notifies all listeners
Returns:
true if the change was consistent, false otherwise.

toString

public String toString()
Specified by:
toString in class ActivityParameter<Location>

getType

public LocationParameter.Type getType()
Returns:
Returns the type.