Updated Branches: refs/heads/develop dcc404689 -> 59659f7cc
http://git-wip-us.apache.org/repos/asf/flex-sdk/blob/fb33548f/modules/debugger/src/java/flex/tools/debugger/cli/FaultActions.java ---------------------------------------------------------------------- diff --git a/modules/debugger/src/java/flex/tools/debugger/cli/FaultActions.java b/modules/debugger/src/java/flex/tools/debugger/cli/FaultActions.java index 3216c38..ec4f4b9 100644 --- a/modules/debugger/src/java/flex/tools/debugger/cli/FaultActions.java +++ b/modules/debugger/src/java/flex/tools/debugger/cli/FaultActions.java @@ -31,13 +31,13 @@ import java.util.HashMap; * * Add new actions by calling addAction("name") */ -class FaultActions +public class FaultActions { - private final HashMap<String, Integer> m_faults = new HashMap<String, Integer>(); - private final HashMap<String, String> m_description = new HashMap<String, String>(); // @todo should really use an object within the faults map for this - private final HashMap<String, Integer> m_actions = new HashMap<String, Integer>(); + HashMap<String, Integer> m_faults = new HashMap<String, Integer>(); + HashMap<String, String> m_description = new HashMap<String, String>(); // @todo should really use an object within the faults map for this + HashMap<String, Integer> m_actions = new HashMap<String, Integer>(); - private int m_nextBitForAction = 0x1; // the next bit to use for the action + int m_nextBitForAction = 0x1; // the next bit to use for the action public FaultActions() {} @@ -50,7 +50,7 @@ class FaultActions public int size() { return m_faults.size(); } public Object[] names() { return m_faults.keySet().toArray(); } public Object[] actions() { return m_actions.keySet().toArray(); } - public boolean exists(String k) { return (get(k) != null); } + public boolean exists(String k) { return (get(k) == null) ? false : true; } public void putDescription(String k, String v) { m_description.put(k,v); } public String getDescription(String k) { return (m_description.get(k) == null) ? "" : m_description.get(k); } //$NON-NLS-1$ @@ -60,7 +60,7 @@ class FaultActions */ public void add(String k) { - put(k, 0); + put(k, new Integer(0)); } /** @@ -68,7 +68,7 @@ class FaultActions */ public void addAction(String k) { - Integer v = m_nextBitForAction++; + Integer v = new Integer(m_nextBitForAction++); m_actions.put(k,v); } @@ -77,10 +77,11 @@ class FaultActions */ public boolean is(String fault, String action) { - int mask = getAction(action); - int bits = get(fault); + int mask = getAction(action).intValue(); + int bits = get(fault).intValue(); - return ((bits & mask) == mask); + boolean set = ( (bits & mask) == mask ) ? true : false; + return set; } /** @@ -105,13 +106,13 @@ class FaultActions throw new IllegalArgumentException(action); // now do the math - int old = current; - int mask = bit; + int old = current.intValue(); + int mask = bit.intValue(); int n = (old & (~mask)); // turn it off n = (no) ? n : (n | mask); // leave it off or turn it on - put(fault, n); + put(fault, new Integer(n)); return n; } http://git-wip-us.apache.org/repos/asf/flex-sdk/blob/fb33548f/modules/debugger/src/java/flex/tools/debugger/cli/FileInfoCache.java ---------------------------------------------------------------------- diff --git a/modules/debugger/src/java/flex/tools/debugger/cli/FileInfoCache.java b/modules/debugger/src/java/flex/tools/debugger/cli/FileInfoCache.java index da00445..8a90988 100644 --- a/modules/debugger/src/java/flex/tools/debugger/cli/FileInfoCache.java +++ b/modules/debugger/src/java/flex/tools/debugger/cli/FileInfoCache.java @@ -38,16 +38,16 @@ import java.util.Iterator; */ public class FileInfoCache implements Comparator<SourceFile> { - private Session m_session; + Session m_session; /** * We can get at files by module id or path */ - private final IntMap m_byInt = new IntMap(); - private SourceFile[] m_files = null; - private SwfInfo m_swfFilter = null; - private int m_swfsLoaded = 0; - private boolean m_dirty = false; + IntMap m_byInt = new IntMap(); + SourceFile[] m_files = null; + SwfInfo m_swfFilter = null; + int m_swfsLoaded = 0; + boolean m_dirty = false; public FileInfoCache() {} @@ -117,7 +117,7 @@ public class FileInfoCache implements Comparator<SourceFile> for(int i=0; i<swfs.length; i++) { if (swfs[i] != null) - worked = loadSwfFiles(files, swfs[i]) && worked; + worked = loadSwfFiles(files, swfs[i]) ? worked : false; } // trim the file list @@ -445,7 +445,7 @@ public class FileInfoCache implements Comparator<SourceFile> fileList.add(sourceFile); else if (doEndsWith && name.endsWith(match)) fileList.add(sourceFile); - else if (doIndexOf && name.contains(match)) + else if (doIndexOf && name.indexOf(match) > -1) fileList.add(sourceFile); } http://git-wip-us.apache.org/repos/asf/flex-sdk/blob/fb33548f/modules/debugger/src/java/flex/tools/debugger/cli/Help.java ---------------------------------------------------------------------- diff --git a/modules/debugger/src/java/flex/tools/debugger/cli/Help.java b/modules/debugger/src/java/flex/tools/debugger/cli/Help.java index 5655e4c..cb2f080 100644 --- a/modules/debugger/src/java/flex/tools/debugger/cli/Help.java +++ b/modules/debugger/src/java/flex/tools/debugger/cli/Help.java @@ -24,7 +24,7 @@ import java.util.ArrayList; import java.util.List; import java.util.Locale; -class Help +public class Help { private Help() { http://git-wip-us.apache.org/repos/asf/flex-sdk/blob/fb33548f/modules/debugger/src/java/flex/tools/debugger/cli/IntProperties.java ---------------------------------------------------------------------- diff --git a/modules/debugger/src/java/flex/tools/debugger/cli/IntProperties.java b/modules/debugger/src/java/flex/tools/debugger/cli/IntProperties.java index 1470808..14ed4ca 100644 --- a/modules/debugger/src/java/flex/tools/debugger/cli/IntProperties.java +++ b/modules/debugger/src/java/flex/tools/debugger/cli/IntProperties.java @@ -22,9 +22,9 @@ package flex.tools.debugger.cli; import java.util.HashMap; import java.util.Set; -class IntProperties +public class IntProperties { - private final HashMap<String, Integer> m_map = new HashMap<String, Integer>(); + HashMap<String, Integer> m_map = new HashMap<String, Integer>(); /* getters */ public Integer getInteger(String s) { return m_map.get(s); } @@ -33,6 +33,6 @@ class IntProperties public HashMap<String, Integer> map() { return m_map; } /* setters */ - public void put(String s, int value) { m_map.put(s, value); } + public void put(String s, int value) { m_map.put(s, new Integer(value)); } } http://git-wip-us.apache.org/repos/asf/flex-sdk/blob/fb33548f/modules/debugger/src/java/flex/tools/debugger/cli/InternalProperty.java ---------------------------------------------------------------------- diff --git a/modules/debugger/src/java/flex/tools/debugger/cli/InternalProperty.java b/modules/debugger/src/java/flex/tools/debugger/cli/InternalProperty.java index 057e012..abdb2ee 100644 --- a/modules/debugger/src/java/flex/tools/debugger/cli/InternalProperty.java +++ b/modules/debugger/src/java/flex/tools/debugger/cli/InternalProperty.java @@ -21,10 +21,10 @@ package flex.tools.debugger.cli; import flash.tools.debugger.expression.NoSuchVariableException; -class InternalProperty +public class InternalProperty { - private final String m_key; - final Object m_value; + String m_key; + Object m_value; public InternalProperty(String key, Object value) { http://git-wip-us.apache.org/repos/asf/flex-sdk/blob/fb33548f/modules/debugger/src/java/flex/tools/debugger/cli/LocationCollection.java ---------------------------------------------------------------------- diff --git a/modules/debugger/src/java/flex/tools/debugger/cli/LocationCollection.java b/modules/debugger/src/java/flex/tools/debugger/cli/LocationCollection.java index 8fb1e2d..a6a8293 100644 --- a/modules/debugger/src/java/flex/tools/debugger/cli/LocationCollection.java +++ b/modules/debugger/src/java/flex/tools/debugger/cli/LocationCollection.java @@ -38,7 +38,7 @@ import flash.tools.debugger.Location; */ public class LocationCollection { - private final ArrayList<Location> m_locations = new ArrayList<Location>(); + private ArrayList<Location> m_locations = new ArrayList<Location>(); public boolean add(Location l) { return m_locations.add(l); } public boolean contains(Location l) { return m_locations.contains(l); } http://git-wip-us.apache.org/repos/asf/flex-sdk/blob/fb33548f/modules/debugger/src/java/flex/tools/debugger/cli/StringIntArray.java ---------------------------------------------------------------------- diff --git a/modules/debugger/src/java/flex/tools/debugger/cli/StringIntArray.java b/modules/debugger/src/java/flex/tools/debugger/cli/StringIntArray.java index 70aefa1..bb12124 100644 --- a/modules/debugger/src/java/flex/tools/debugger/cli/StringIntArray.java +++ b/modules/debugger/src/java/flex/tools/debugger/cli/StringIntArray.java @@ -30,11 +30,11 @@ import java.util.AbstractList; * which returns a ArrayList of index numbers for each element whose * String component matches the provided argument. */ -class StringIntArray extends AbstractList<Object> +public class StringIntArray extends AbstractList<Object> { - private Object[] m_ar; - private int m_size = 0; - private final double m_growthRatio = 1.60; + Object[] m_ar; + int m_size = 0; + double m_growthRatio = 1.60; public StringIntArray(Object[] ar) { @@ -44,7 +44,7 @@ class StringIntArray extends AbstractList<Object> public StringIntArray() { this(10); } - private StringIntArray(int size) + public StringIntArray(int size) { m_ar = new Object[size]; m_size = 0; @@ -53,7 +53,7 @@ class StringIntArray extends AbstractList<Object> public Object get(int at) { return m_ar[at]; } public int size() { return m_size; } - Object[] getElement(int at) { return (Object[])get(at); } + public Object[] getElement(int at) { return (Object[])get(at); } public String getString(int at) { return (String)getElement(at)[0]; } public Integer getInteger(int at) { return (Integer)getElement(at)[1]; } public int getInt(int at) { return getInteger(at).intValue(); } @@ -68,7 +68,7 @@ class StringIntArray extends AbstractList<Object> ArrayList<Integer> alist = new ArrayList<Integer>(); for(int i=0; i<m_size; i++) if ( getString(i).startsWith(s) ) - alist.add(i); + alist.add( new Integer(i) ); return alist; } http://git-wip-us.apache.org/repos/asf/flex-sdk/blob/fb33548f/modules/debugger/src/java/flex/tools/debugger/cli/VariableFacade.java ---------------------------------------------------------------------- diff --git a/modules/debugger/src/java/flex/tools/debugger/cli/VariableFacade.java b/modules/debugger/src/java/flex/tools/debugger/cli/VariableFacade.java index db14730..c2cdd48 100644 --- a/modules/debugger/src/java/flex/tools/debugger/cli/VariableFacade.java +++ b/modules/debugger/src/java/flex/tools/debugger/cli/VariableFacade.java @@ -37,10 +37,10 @@ import flash.tools.debugger.events.FaultEvent; */ public class VariableFacade implements Variable { - private Variable m_var; - private long m_context; - private String m_name; - private String m_path; + Variable m_var; + long m_context; + String m_name; + String m_path; public VariableFacade(Variable v, long context) { init(context, v, null); } public VariableFacade(long context, String name) { init(context, null, name); } http://git-wip-us.apache.org/repos/asf/flex-sdk/blob/fb33548f/modules/debugger/src/java/flex/tools/debugger/cli/WatchAction.java ---------------------------------------------------------------------- diff --git a/modules/debugger/src/java/flex/tools/debugger/cli/WatchAction.java b/modules/debugger/src/java/flex/tools/debugger/cli/WatchAction.java index dac9826..74dfa6d 100644 --- a/modules/debugger/src/java/flex/tools/debugger/cli/WatchAction.java +++ b/modules/debugger/src/java/flex/tools/debugger/cli/WatchAction.java @@ -25,10 +25,10 @@ import flash.tools.debugger.Watch; * An object that relates a CLI debugger watchpoint with the * actual Watch obtained from the Session */ -class WatchAction +public class WatchAction { - private Watch m_watch; - private int m_id; + Watch m_watch; + int m_id; public WatchAction(Watch w) { @@ -43,7 +43,7 @@ class WatchAction /* getters */ public int getId() { return m_id; } - long getVariableId() { return m_watch.getValueId(); } + public long getVariableId() { return m_watch.getValueId(); } public int getKind() { return m_watch.getKind(); } public Watch getWatch() { return m_watch; }
