Added size() method to FlightConfiguration and FlightConfigurationImpl
to determine if a component has any flight configurations other than default.
This commit is contained in:
parent
8b6541284c
commit
8dea8f9395
@ -66,4 +66,9 @@ public interface FlightConfiguration<E extends ChangeSource> extends FlightConfi
|
|||||||
*/
|
*/
|
||||||
public void resetDefault(String id);
|
public void resetDefault(String id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Return the number of specific flight configurations other than the default.
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
public int size();
|
||||||
}
|
}
|
||||||
|
@ -81,6 +81,12 @@ class FlightConfigurationImpl<E extends FlightConfigurableParameter<E>> implemen
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public int size() {
|
||||||
|
return map.size();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public E get(String id) {
|
public E get(String id) {
|
||||||
if (map.containsKey(id)) {
|
if (map.containsKey(id)) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user