Issue #2711 Use level factory more.
Former-commit-id:3d9b435262
[formerly1069ef8d67
] [formerlyd7a3ae4fdb
] [formerly3da086b71f
[formerlyd7a3ae4fdb
[formerly db58ae5999ea088cb93a8016836a6c62efe347e4]]] Former-commit-id:3da086b71f
Former-commit-id: 81be956862611f9499f1e2716026d69eacf91f27 [formerlyf45646ae91
] Former-commit-id:29f9a87085
This commit is contained in:
parent
715c69bd2a
commit
4d1276def2
2 changed files with 20 additions and 23 deletions
|
@ -63,17 +63,19 @@ import com.raytheon.viz.grid.rsc.GridResourceData;
|
|||
* <pre>
|
||||
*
|
||||
* SOFTWARE HISTORY
|
||||
* Date Ticket# Engineer Description
|
||||
* ------------ ---------- ----------- --------------------------
|
||||
* May 21, 2010 bsteffens Initial creation
|
||||
* May 26, 2010 mnash Used ProductBrowserLabel implementation instead of requery
|
||||
* May 02, 2013 1949 bsteffen Switch Product Browser from uengine to
|
||||
* DbQueryRequest.
|
||||
* Sep 19, 2013 2391 mpduff refactored some methods to common class.
|
||||
* Date Ticket# Engineer Description
|
||||
* ------------- -------- ----------- --------------------------
|
||||
* May 21, 2010 bsteffen Initial creation
|
||||
* May 26, 2010 mnash Used ProductBrowserLabel implementation
|
||||
* instead of requery
|
||||
* May 02, 2013 1949 bsteffen Switch Product Browser from uengine to
|
||||
* DbQueryRequest.
|
||||
* Sep 19, 2013 2391 mpduff refactored some methods to common class.
|
||||
* Jan 23, 2014 2711 bsteffen Get all levels from LevelFactory.
|
||||
*
|
||||
* </pre>
|
||||
*
|
||||
* @author bsteffens
|
||||
* @author bsteffen
|
||||
* @version 1.0
|
||||
*/
|
||||
public class GridProductBrowserDataDefinition extends
|
||||
|
@ -172,11 +174,8 @@ public class GridProductBrowserDataDefinition extends
|
|||
params = Arrays.asList(value);
|
||||
} else if (key.equals(GridInventory.MASTER_LEVEL_QUERY)) {
|
||||
if (levels == null) {
|
||||
levels = new ArrayList<Level>(
|
||||
LevelMappingFactory
|
||||
.getInstance(
|
||||
LevelMappingFactory.VOLUMEBROWSER_LEVEL_MAPPING_FILE)
|
||||
.getAllLevels());
|
||||
levels = new ArrayList<Level>(LevelFactory
|
||||
.getInstance().getAllLevels());
|
||||
}
|
||||
Iterator<Level> iter = levels.iterator();
|
||||
while (iter.hasNext()) {
|
||||
|
|
|
@ -20,11 +20,11 @@
|
|||
package com.raytheon.uf.common.dataplugin.level.util;
|
||||
|
||||
import java.text.ParsePosition;
|
||||
import java.util.Collection;
|
||||
import java.util.Comparator;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
import java.util.NavigableSet;
|
||||
import java.util.Set;
|
||||
import java.util.TreeSet;
|
||||
|
||||
import javax.measure.unit.Unit;
|
||||
|
@ -35,7 +35,6 @@ import com.raytheon.uf.common.dataplugin.level.CompareType;
|
|||
import com.raytheon.uf.common.dataplugin.level.Level;
|
||||
import com.raytheon.uf.common.dataplugin.level.LevelFactory;
|
||||
import com.raytheon.uf.common.dataplugin.level.MasterLevel;
|
||||
import com.raytheon.uf.common.dataplugin.level.mapping.LevelMappingFactory;
|
||||
|
||||
/**
|
||||
* Level utilities
|
||||
|
@ -45,11 +44,12 @@ import com.raytheon.uf.common.dataplugin.level.mapping.LevelMappingFactory;
|
|||
*
|
||||
* SOFTWARE HISTORY
|
||||
*
|
||||
* Date Ticket# Engineer Description
|
||||
* ------------ ---------- ----------- --------------------------
|
||||
* 11/21/2009 #3576 rjpeter Initial version
|
||||
* 01/30/2014 #2725 ekladstrup Moved to common and removed
|
||||
* usage of VizCommunicationException
|
||||
* Date Ticket# Engineer Description
|
||||
* ------------- -------- ----------- --------------------------
|
||||
* Nov 21, 2009 3576 rjpeter Initial version
|
||||
* Jan 30, 2014 2725 ekladstrup Moved to common and removed
|
||||
* usage of VizCommunicationException
|
||||
* Jan 23, 2014 2711 bsteffen Get all levels from LevelFactory.
|
||||
* </pre>
|
||||
*
|
||||
* @author rjpeter
|
||||
|
@ -117,9 +117,7 @@ public class LevelUtilities {
|
|||
|
||||
};
|
||||
Map<String, NavigableSet<Level>> masterLevelToOrderedSet = new HashMap<String, NavigableSet<Level>>();
|
||||
Set<Level> allLevels;
|
||||
allLevels = LevelMappingFactory.getInstance(
|
||||
LevelMappingFactory.VOLUMEBROWSER_LEVEL_MAPPING_FILE)
|
||||
Collection<Level> allLevels = LevelFactory.getInstance()
|
||||
.getAllLevels();
|
||||
for (Level level : allLevels) {
|
||||
NavigableSet<Level> levels = masterLevelToOrderedSet.get(level
|
||||
|
|
Loading…
Add table
Reference in a new issue