bugged
stringlengths
6
599k
fixed
stringlengths
10
599k
__index_level_0__
int64
0
1.13M
private int convertBytesToInteger (int numOfBytes, String endianStyle, byte[] bb, int sbyte) { // is it better to use a dispatch table here? switch (numOfBytes) { case 1: // 8-bit return convert1byteToInteger (bb, sbyte); case 2: // 16-bit return convert...
private int convertBytesToInteger (int numOfBytes, String endianStyle, byte[] bb, int sbyte) { // is it better to use a dispatch table here? switch (numOfBytes) { case 1: // 8-bit return convert1byteToInteger (bb, sbyte); case 2: // 16-bit return convert...
7,638
public void toXMLOutputStream ( OutputStream outputstream, Hashtable XMLDeclAttribs, String strIndent, boolean dontCloseNode, String newNodeNameStri...
public void toXMLOutputStream ( OutputStream outputstream, Hashtable XMLDeclAttribs, String strIndent, boolean dontCloseNode, String newNodeNameStri...
7,639
protected void writeDelimitedData(OutputStream outputstream, Locator locator, DelimitedXMLDataIOStyle readObj, AxisInterface fastestAxis, String[] noDataValues) { String delimiter = readObj.getDelimiter(); S...
private void writeDelimitedData(OutputStream outputstream, Locator locator, DelimitedXMLDataIOStyle readObj, AxisInterface fastestAxis, String[] noDataValues) { String delimiter = readObj.getDelimiter(); Str...
7,640
protected void writeFormattedData(OutputStream outputstream , Locator locator, FormattedXMLDataIOStyle readObj, AxisInterface fastestAxis, String[] noDataValues) { writeOut(outputstream...
private void writeFormattedData(OutputStream outputstream , Locator locator, FormattedXMLDataIOStyle readObj, AxisInterface fastestAxis, String[] noDataValues) { writeOut(outputstream, ...
7,641
protected void writeTaggedData(OutputStream outputstream, Locator locator, String indent, int[] axisLength, String[] tags, int which, AxisInterface fastestAxis, String[] noDataValues) { String tag = (String) tag...
protected void writeTaggedData(OutputStream outputstream, Locator locator, String indent, int[] axisLength, String[] tags, int which, AxisInterface fastestAxis, String[] noDataValues) { String tag = (String) tag...
7,642
protected void writeTaggedData(OutputStream outputstream, Locator locator, String indent, int[] axisLength, String[] tags, int which, AxisInterface fastestAxis, String[] noDataValues) { String tag = (String) tag...
protected void writeTaggedData(OutputStream outputstream, Locator locator, String indent, int[] axisLength, String[] tags, int which, AxisInterface fastestAxis, String[] noDataValues) { String tag = (String) tag...
7,643
protected void writeTaggedData(OutputStream outputstream, Locator locator, String indent, int[] axisLength, String[] tags, int which, AxisInterface fastestAxis, String[] noDataValues) { String tag = (String) tag...
protected void writeTaggedData(OutputStream outputstream, Locator locator, String indent, int[] axisLength, String[] tags, int which, AxisInterface fastestAxis, String[] noDataValues) { String tag = (String) tag...
7,644
public synchronized void add(String item) { if (item == null) throw new NullPointerException("item must be non-null"); pItems.addElement(item); int i = pItems.size() - 1; if (peer != null) { ChoicePeer cp = (ChoicePeer) peer; cp.add(item, i); } if (i == 0) select(0); }
add(String item) { if (item == null) throw new NullPointerException("item must be non-null"); pItems.addElement(item); int i = pItems.size() - 1; if (peer != null) { ChoicePeer cp = (ChoicePeer) peer; cp.add(item, i); } if (i == 0) select(0); }
7,645
public synchronized void add(String item) { if (item == null) throw new NullPointerException("item must be non-null"); pItems.addElement(item); int i = pItems.size() - 1; if (peer != null) { ChoicePeer cp = (ChoicePeer) peer; cp.add(item, i); } if (i == 0) select(0); }
public synchronized void add(String item) { if (item == null) throw new NullPointerException("item must be non-null"); pItems.addElement(item); int i = pItems.size() - 1; if (peer != null) { ChoicePeer cp = (ChoicePeer) peer; cp.add(item, i); } if (i == 0) select(0); }
7,646
public synchronized void addItem(String item) { add(item); }
addItem(String item) { add(item); }
7,647
public synchronized void addItemListener(ItemListener listener) { item_listeners = AWTEventMulticaster.add(item_listeners, listener); }
addItemListener(ItemListener listener) { item_listeners = AWTEventMulticaster.add(item_listeners, listener); }
7,648
public void addNotify() { if (peer == null) peer = getToolkit().createChoice(this); super.addNotify(); }
addNotify() { if (peer == null) peer = getToolkit().createChoice(this); super.addNotify(); }
7,649
public int countItems() { return (pItems.size()); }
public int countItems() { return (pItems.size()); }
7,650
public String getItem(int index) { return ((String) pItems.elementAt(index)); }
public String getItem(int index) { return ((String) pItems.elementAt(index)); }
7,651
public int getItemCount() { return (pItems.size()); }
public int getItemCount() { return (pItems.size()); }
7,652
public int getSelectedIndex() { return (selectedIndex); }
public int getSelectedIndex() { return (selectedIndex); }
7,653
public synchronized String getSelectedItem() { return (selectedIndex == -1 ? null : ((String) pItems.elementAt(selectedIndex))); }
public synchronized String getSelectedItem() { return (selectedIndex == -1 ? null : ((String) pItems.elementAt(selectedIndex))); }
7,654
public synchronized Object[] getSelectedObjects() { if (selectedIndex == -1) return null; Object[] objs = new Object[1]; objs[0] = pItems.elementAt(selectedIndex); return (objs); }
getSelectedObjects() { if (selectedIndex == -1) return null; Object[] objs = new Object[1]; objs[0] = pItems.elementAt(selectedIndex); return (objs); }
7,655
public synchronized void insert(String item, int index) { if (index < 0) throw new IllegalArgumentException("index may not be less then 0"); if (index > getItemCount()) index = getItemCount(); pItems.insertElementAt(item, index); if (peer != null) { ChoicePeer cp = (ChoicePeer) peer; cp.add(item, index); ...
insert(String item, int index) { if (index < 0) throw new IllegalArgumentException("index may not be less then 0"); if (index > getItemCount()) index = getItemCount(); pItems.insertElementAt(item, index); if (peer != null) { ChoicePeer cp = (ChoicePeer) peer; cp.add(item, index); } if (getItemCount() == ...
7,656
public synchronized void insert(String item, int index) { if (index < 0) throw new IllegalArgumentException("index may not be less then 0"); if (index > getItemCount()) index = getItemCount(); pItems.insertElementAt(item, index); if (peer != null) { ChoicePeer cp = (ChoicePeer) peer; cp.add(item, index); ...
public synchronized void insert(String item, int index) { if (index < 0) throw new IllegalArgumentException("index may not be less then 0"); if (index > getItemCount()) index = getItemCount(); pItems.insertElementAt(item, index); if (peer != null) { ChoicePeer cp = (ChoicePeer) peer; cp.add(item, index); ...
7,657
protected String paramString() { return ("selectedIndex=" + selectedIndex + "," + super.paramString()); }
paramString() { return ("selectedIndex=" + selectedIndex + "," + super.paramString()); }
7,658
public synchronized void remove(String item) { int index = pItems.indexOf(item); if (index == -1) throw new IllegalArgumentException("item \"" + item + "\" not found in Choice"); remove(index); }
remove(String item) { int index = pItems.indexOf(item); if (index == -1) throw new IllegalArgumentException("item \"" + item + "\" not found in Choice"); remove(index); }
7,659
public synchronized void removeAll() { int count = getItemCount(); for (int i = 0; i < count; i++) { // Always remove 0. remove(0); } }
public synchronized void removeAll() { int count = getItemCount(); for (int i = 0; i < count; i++) { // Always remove 0. remove(0); } }
7,660
public synchronized void removeAll() { int count = getItemCount(); for (int i = 0; i < count; i++) { // Always remove 0. remove(0); } }
public synchronized void removeAll() { int count = getItemCount(); for (int i = 0; i < count; i++) { // Always remove 0. remove(0); } }
7,661
public synchronized void select(int index) { if ((index < 0) || (index > getItemCount())) throw new IllegalArgumentException("Bad index: " + index); this.selectedIndex = index; if (peer != null) { ChoicePeer cp = (ChoicePeer) peer; cp.select(index); } }
select(int index) { if ((index < 0) || (index > getItemCount())) throw new IllegalArgumentException("Bad index: " + index); this.selectedIndex = index; if (peer != null) { ChoicePeer cp = (ChoicePeer) peer; cp.select(index); } }
7,663
public synchronized void select(int index) { if ((index < 0) || (index > getItemCount())) throw new IllegalArgumentException("Bad index: " + index); this.selectedIndex = index; if (peer != null) { ChoicePeer cp = (ChoicePeer) peer; cp.select(index); } }
public synchronized void select(int index) { if ((index < 0) || (index > getItemCount())) throw new IllegalArgumentException("Bad index: " + index); this.selectedIndex = index; if (peer != null) { ChoicePeer cp = (ChoicePeer) peer; cp.select(index); } }
7,664
private int getDaysInMonth(int month, int year) { // Most of this is copied from GregorianCalendar.getActualMaximum() if (month == Calendar.FEBRUARY) { return ((year & 3) == 0 && (year % 100 != 0 || year % 400 == 0)) ? 29 : 28; } else if (month < Calendar.AUGUST) return 31 - (month & 1); ...
private int getDaysInMonth(int month, int year) { // Most of this is copied from GregorianCalendar.getActualMaximum() if (month == Calendar.FEBRUARY) { return ((year & 3) == 0 && (year % 100 != 0 || year % 400 == 0)) ? 29 : 28; } else if (month < Calendar.AUGUST) return 31 - (month & 1); ...
7,667
private int getDaysInMonth(int month, int year) { // Most of this is copied from GregorianCalendar.getActualMaximum() if (month == Calendar.FEBRUARY) { return ((year & 3) == 0 && (year % 100 != 0 || year % 400 == 0)) ? 29 : 28; } else if (month < Calendar.AUGUST) return 31 - (month & 1); ...
private int getDaysInMonth(int month, int year) { // Most of this is copied from GregorianCalendar.getActualMaximum() if (month == Calendar.FEBRUARY) { return ((year & 3) == 0 && (year % 100 != 0 || year % 400 == 0)) ? 29 : 28; } else if (month < Calendar.AUGUST) return 31 - (month & 1); ...
7,668
private int getDaysInMonth(int month, int year) { // Most of this is copied from GregorianCalendar.getActualMaximum() if (month == Calendar.FEBRUARY) { return ((year & 3) == 0 && (year % 100 != 0 || year % 400 == 0)) ? 29 : 28; } else if (month < Calendar.AUGUST) return 31 - (month & 1); ...
private int getDaysInMonth(int month, int year) { // Most of this is copied from GregorianCalendar.getActualMaximum() if (month == Calendar.FEBRUARY) { return ((year & 3) == 0 && (year % 100 != 0 || year % 400 == 0)) ? 29 : 28; } else if (month < Calendar.AUGUST) return 31 - (month & 1); ...
7,669
public int getOffset(int era, int year, int month, int day, int dayOfWeek, int millis) { int daysInMonth = getDaysInMonth(month, year); if (day < 1 || day > daysInMonth) throw new IllegalArgumentException("day out of range"); if (dayOfWeek < Calendar.SUNDAY || dayOfWeek > Calendar.SATURDAY) ...
public int getOffset(int era, int year, int month, int day, int dayOfWeek, int millis) { int daysInMonth = getDaysInMonth(month, year); if (day < 1 || day > daysInMonth) throw new IllegalArgumentException("day out of range"); if (dayOfWeek < Calendar.SUNDAY || dayOfWeek > Calendar.SATURDAY) ...
7,670
public int getOffset(int era, int year, int month, int day, int dayOfWeek, int millis) { int daysInMonth = getDaysInMonth(month, year); if (day < 1 || day > daysInMonth) throw new IllegalArgumentException("day out of range"); if (dayOfWeek < Calendar.SUNDAY || dayOfWeek > Calendar.SATURDAY) ...
public int getOffset(int era, int year, int month, int day, int dayOfWeek, int millis) int daysInMonth = getDaysInMonth(month, year); if (day < 1 || day > daysInMonth) throw new IllegalArgumentException("day out of range"); if (dayOfWeek < Calendar.SUNDAY || dayOfWeek > Calendar.SATURDAY) ...
7,671
public int getOffset(int era, int year, int month, int day, int dayOfWeek, int millis) { int daysInMonth = getDaysInMonth(month, year); if (day < 1 || day > daysInMonth) throw new IllegalArgumentException("day out of range"); if (dayOfWeek < Calendar.SUNDAY || dayOfWeek > Calendar.SATURDAY) ...
public int getOffset(int era, int year, int month, int day, int dayOfWeek, int millis) { int daysInMonth = getDaysInMonth(month, year); if (day < 1 || day > daysInMonth) throw new IllegalArgumentException("day out of range"); if (dayOfWeek < Calendar.SUNDAY || dayOfWeek > Calendar.SATURDAY) ...
7,672
public int getScrollableBlockIncrement(Rectangle visibleRect, int orientation, int direction) { return getScrollableUnitIncrement(visibleRect, orientation, direction); }
public int getScrollableBlockIncrement(Rectangle visibleRect, int orientation, int direction) { int block; if (orientation == SwingConstants.VERTICAL) block = visibleRect.height; else block = visibleRect.width; return block; }
7,673
public int getScrollableUnitIncrement(Rectangle visibleRect, int orientation, int direction) { int delta; // Round so that the top would start from the row boundary if (orientation == SwingConstants.VERTICAL) { // One pixel down, otherwise picks another row...
public int getScrollableUnitIncrement(Rectangle visibleRect, int orientation, int direction) { int delta = 0; // Round so that the top would start from the row boundary if (orientation == SwingConstants.VERTICAL) { // One pixel down, otherwise picks another...
7,674
public int getScrollableUnitIncrement(Rectangle visibleRect, int orientation, int direction) { int delta; // Round so that the top would start from the row boundary if (orientation == SwingConstants.VERTICAL) { // One pixel down, otherwise picks another row...
public int getScrollableUnitIncrement(Rectangle visibleRect, int orientation, int direction) { int delta; // Round so that the top would start from the row boundary if (orientation == SwingConstants.VERTICAL) { // One pixel down, otherwise picks another row...
7,675
public int getScrollableUnitIncrement(Rectangle visibleRect, int orientation, int direction) { int delta; // Round so that the top would start from the row boundary if (orientation == SwingConstants.VERTICAL) { // One pixel down, otherwise picks another row...
public int getScrollableUnitIncrement(Rectangle visibleRect, int orientation, int direction) { int delta; // Round so that the top would start from the row boundary if (orientation == SwingConstants.VERTICAL) { // One pixel down, otherwise picks another row...
7,676
public void setSelectionModel(TreeSelectionModel model) { if (selectionModel == model) return; if (selectionModel != null) selectionModel.removeTreeSelectionListener(selectionRedirector); TreeSelectionModel oldValue = selectionModel; selectionModel = model; if (selectionModel != null) s...
public void setSelectionModel(TreeSelectionModel model) { if (selectionModel == model) return; selectionModel.removeTreeSelectionListener(selectionRedirector); TreeSelectionModel oldValue = selectionModel; selectionModel = model; selectionModel.addTreeSelectionListener(selectionRedire...
7,677
private LongItem(int kind, int offsetToFP, Register lsb, Register msb, long val) { super(kind, offsetToFP, lsb, msb); this.value = val; }
private LongItem(int kind, int offsetToFP, Register lsb, Register msb, long val) { super(kind, offsetToFP, lsb, msb); this.value = val; }
7,678
protected DoubleWordItem cloneConstant() { return createConst(getValue()); }
protected DoubleWordItem cloneConstant() { return createConst(getValue()); }
7,679
public synchronized void connect() throws IOException { // Call is ignored if already connected. if (connected) return; jar_url = getJarFileURL(); jar_file = JarFileCache.get (jar_url, useCaches); String entry_name = getEntryName(); if (entry_name != null && !entry_name.equals (""))...
public synchronized void connect() throws IOException { // Call is ignored if already connected. if (connected) return; jar_url = getJarFileURL(); jar_file = JarFileCache.get (jar_url, useCaches); String entry_name = getEntryName(); if (entry_name != null && !entry_name.equals (""))...
7,685
public InputStream getInputStream() throws IOException { if (!connected) connect(); if (! doInput) throw new ProtocolException("Can't open InputStream if doInput is false"); if (jar_entry == null) throw new IOException (jar_url + " couldn't be found."); return jar_file.getInputStre...
public InputStream getInputStream() throws IOException { if (!connected) connect(); if (! doInput) throw new ProtocolException("Can't open InputStream if doInput is false"); if (jar_entry == null) throw new IOException (jar_url + " couldn't be found."); return jar_file.getInputStre...
7,686
protected JButton createArrowButton() { return new MetalComboBoxButton(comboBox, new MetalComboBoxIcon(), new CellRendererPane(), listBox); }
protected JButton createArrowButton() { JButton button = new MetalComboBoxButton(comboBox, new MetalComboBoxIcon(), new CellRendererPane(), listBox); }
7,687
protected void editablePropertyChanged(PropertyChangeEvent e) { if (arrowButton instanceof MetalComboBoxButton) { MetalComboBoxButton b = (MetalComboBoxButton) arrowButton; b.setIconOnly(comboBox.isEditable()); } if (comboBox.isEditable()) { arrowButton.setText(null); ...
protected void editablePropertyChanged(PropertyChangeEvent e) { if (arrowButton instanceof MetalComboBoxButton) { MetalComboBoxButton b = (MetalComboBoxButton) arrowButton; b.setIconOnly(comboBox.isEditable()); } if (comboBox.isEditable()) { arrowButton.setText(null); ...
7,689
public Dimension getMinimumSize(JComponent c) { // FIXME: this needs work Dimension result = super.getMinimumSize(c); result.height = result.height + 9; return result; }
public Dimension getMinimumSize(JComponent c) { // FIXME: this needs work Dimension result = super.getMinimumSize(c); result.height = result.height + 9; return result; }
7,690
protected PropertyChangeListener createActionPropertyChangeListener(Action action) { return new PropertyChangeListener() { public void propertyChange(PropertyChangeEvent event) { // Update properties "action" and "horizontalAlignment". String name = event.getPropertyName(); if (name.equals("enabled")) ...
protected PropertyChangeListener createActionPropertyChangeListener(Action action) { return new PropertyChangeListener() { public void propertyChange(PropertyChangeEvent event) { // Update properties "action" and "horizontalAlignment". String name = event.getPropertyName(); if (name.equals("enabled")) ...
7,691
void findHelper() { if (helper != null || helper_NA) return; try { Class helperClass = Class.forName(ObjectCreator.toHelperName(type.id())); helper = (BoxedValueHelper) helperClass.newInstance(); } catch (Exception ex) { helper_NA = true; } }
void findHelper() { if (helper != null || helper_NA) return; try { Class helperClass = ObjectCreator.forName(ObjectCreator.toHelperName(type.id())); helper = (BoxedValueHelper) helperClass.newInstance(); } catch (Exception ex) { helper_NA = true; } }
7,692
public void send() throws Exception, AddressException, MessagingException {// try { if(!loadConfig(configFile)) return; Session session = Session.getDefaultInstance(SMTPProperties, null); session.setDebug(false); // create the Multipart and its parts to it Mult...
public boolean send() throws Exception, AddressException, MessagingException {// try { if(!loadConfig(configFile)) return; Session session = Session.getDefaultInstance(SMTPProperties, null); session.setDebug(false); // create the Multipart and its parts to it M...
7,693
public void send() throws Exception, AddressException, MessagingException {// try { if(!loadConfig(configFile)) return; Session session = Session.getDefaultInstance(SMTPProperties, null); session.setDebug(false); // create the Multipart and its parts to it Mult...
public void send() throws Exception, AddressException, MessagingException {// try { if(!loadConfig(configFile)) return false; Session session = Session.getDefaultInstance(SMTPProperties, null); session.setDebug(false); // create the Multipart and its parts to it ...
7,695
public static NotEmpty extract(Any a) { try { return ((NotEmptyHolder) a.extract_Streamable()).value; } catch (ClassCastException ex) { throw new BAD_OPERATION(); } }
public static NotEmpty extract(Any a) { try { return ((NotEmptyHolder) a.extract_Streamable()).value; } catch (ClassCastException ex) { BAD_OPERATION bad = new BAD_OPERATION(); bad.initCause(ex); bad.minor = Minor.Any; throw bad; } }
7,697
public Object addMemberObject (Object obj) { if (obj!=null) { if (memberObjHash.add(obj)) return obj; else return null; } else return null; }
public Object addMemberObject (Object obj) { if (obj!=null) { if (memberObjHash.add(obj)) return obj; else return null; } else return null; }
7,698
public boolean hasMemberObj (Object obj) { if (obj!=null) { if (memberObjHash.contains(obj)) { return true; } else return false; } return false; }
public boolean hasMemberObj (Object obj) { if (obj!=null) { if (memberObjHash.contains(obj)) { return true; } else return false; } return false; }
7,699
public boolean hasMemberObj (Object obj) { if (obj!=null) { if (memberObjHash.contains(obj)) { return true; } else return false; } return false; }
public boolean hasMemberObj (Object obj) { if (obj!=null) { if (memberObjHash.contains(obj)) { return true; } else else return false; } else return false; }
7,700
public Object removeMemberObject (Object obj) { if (obj!=null) { if (memberObjHash.contains(obj)) { memberObjHash.remove(obj); return obj; } else return null; } else return null; }
public Object removeMemberObject (Object obj) { if (obj!=null) { if (memberObjHash.contains(obj)) { memberObjHash.remove(obj); return obj; } else return null; } else return null; }
7,701
public Robot() throws AWTException { throw new Error("not implemented"); }
public Robot() throws AWTException { if (GraphicsEnvironment.isHeadless ()) throw new AWTException ("Robot: headless graphics environment"); SecurityManager sm = System.getSecurityManager (); if (sm != null) sm.checkPermission (new AWTPermission ("createRobot")); ClasspathToolkit tk = (ClasspathToolkit) Toolkit...
7,702
public BufferedImage createScreenCapture(Rectangle screen) { return null; }
public BufferedImage createScreenCapture (Rectangle screenRect) { return null; }
7,703
public BufferedImage createScreenCapture(Rectangle screen) { return null; }
public BufferedImage createScreenCapture(Rectangle screen) { if (screenRect.width <= 0) throw new IllegalArgumentException ("Robot: capture width is <= 0"); if (screenRect.height <= 0) throw new IllegalArgumentException ("Robot: capture height is <= 0"); SecurityManager sm = System.getSecurityManager (); if (sm...
7,704
public void delay(int ms) { if (ms < 0 || ms > 60000) throw new IllegalArgumentException(); }
public void delay(int ms) { if (ms < 0 || ms > 60000) throw new IllegalArgumentException ("Robot: delay length out-of-bounds"); try { Thread.sleep (ms); } catch (InterruptedException e) { System.err.println ("Robot: delay interrupted"); } }
7,705
public Color getPixelColor(int x, int y) { return null; }
public Color getPixelColor(int x, int y) { return new Color (peer.getRGBPixel (x, y)); }
7,706
public void setAutoDelay(int ms) { if (ms < 0 || ms > 60000) throw new IllegalArgumentException(); autoDelay = ms; }
public void setAutoDelay(int ms) { if (ms < 0 || ms > 60000) throw new IllegalArgumentException(); autoDelay = ms; }
7,713
public void setAutoWaitForIdle(boolean value) { waitForIdle = value; }
public void setAutoWaitForIdle (boolean isOn) { waitForIdle = value; }
7,714
public void setAutoWaitForIdle(boolean value) { waitForIdle = value; }
public void setAutoWaitForIdle(boolean value) { waitForIdle = isOn; }
7,715
public String toString() { return "unimplemented"; }
public String toString() { return getClass ().getName () + "[ autoDelay = " + autoDelay + ", autoWaitForIdle = " + waitForIdle + " ]"; }
7,716
public TypeCode _type() { return t_fixed; }
public TypeCode _type() { return new fixedTypeCode(value); }
7,718
public static Object allocObject(VmType<?> vmClass, int size) throws UninterruptiblePragma { vmClass.link(); // Screen.debug("ao cls{"); // Screen.debug(vmClass.getName()); VmHeapManager hm = heapManager; if (hm == null) { heapManager = hm = Vm.getHeapManager...
public static Object allocObject(VmType<?> vmClass, int size) throws UninterruptiblePragma { // Screen.debug("ao cls{"); // Screen.debug(vmClass.getName()); VmHeapManager hm = heapManager; if (hm == null) { heapManager = hm = Vm.getHeapManager(); } ...
7,719
public static Object allocObject(VmType<?> vmClass, int size) throws UninterruptiblePragma { vmClass.link(); // Screen.debug("ao cls{"); // Screen.debug(vmClass.getName()); VmHeapManager hm = heapManager; if (hm == null) { heapManager = hm = Vm.getHeapManager...
public static Object allocObject(VmType<?> vmClass, int size) throws UninterruptiblePragma { vmClass.link(); // Screen.debug("ao cls{"); // Screen.debug(vmClass.getName()); VmHeapManager hm = heapManager; if (hm == null) { heapManager = hm = Vm.getHeapManager...
7,720
public void actionPerformed(ActionEvent e) { if (e.getActionCommand().equals("DONE")) { saveProps(); setVisible(false); } if (e.getActionCommand().equals("ADD")) { Configure.doEntry((JFrame)getParent(),null,props); ctm.addSession(); } if (e.getActionCommand()....
public void actionPerformed(ActionEvent e) { if (e.getActionCommand().equals("DONE")) { saveProps(); setVisible(false); } if (e.getActionCommand().equals("ADD")) { Configure.doEntry((JFrame)getParent(),null,props); ctm.addSession(); } if (e.getActionCommand()....
7,721
void jbInit() throws Exception { // make it non resizable setResizable(false); this.setDefaultCloseOperation(JDialog.DISPOSE_ON_CLOSE); // create some reusable borders and layouts Border etchedBorder = BorderFactory.createEtchedBorder(); BorderLayout borderLayout = new BorderLayout(); ...
void jbInit() throws Exception { // make it non resizable setResizable(true); this.setDefaultCloseOperation(JDialog.DISPOSE_ON_CLOSE); // create some reusable borders and layouts Border etchedBorder = BorderFactory.createEtchedBorder(); BorderLayout borderLayout = new BorderLayout(); ...
7,722
void jbInit() throws Exception { // make it non resizable setResizable(false); this.setDefaultCloseOperation(JDialog.DISPOSE_ON_CLOSE); // create some reusable borders and layouts Border etchedBorder = BorderFactory.createEtchedBorder(); BorderLayout borderLayout = new BorderLayout(); ...
void jbInit() throws Exception { // make it non resizable setResizable(false); this.setDefaultCloseOperation(JDialog.DISPOSE_ON_CLOSE); // create some reusable borders and layouts Border etchedBorder = BorderFactory.createEtchedBorder(); BorderLayout borderLayout = new BorderLayout(); ...
7,723
private static PreferencesFactory getFactory() throws SecurityException { // First check for permission SecurityManager sm = System.getSecurityManager(); if (sm != null) { sm.checkPermission(prefsPermission); } // Get the factory if (factory == null) { ...
private static PreferencesFactory getFactory() throws SecurityException { // First check for permission SecurityManager sm = System.getSecurityManager(); if (sm != null) { sm.checkPermission(prefsPermission); } // Get the factory if (factory == null) { ...
7,725
public NodeReader(InputStream is, PreferencesFactory factory) { this(new InputStreamReader(is), factory); }
public NodeReader(InputStream is, PreferencesFactory factory) { this(new InputStreamReader(is), factory); }
7,726
public KeyPair generate() { if (p == null) { BigInteger[] params = new FIPS186(L, rnd).generateParameters(); seed = params[FIPS186.DSA_PARAMS_SEED]; counter = params[FIPS186.DSA_PARAMS_COUNTER]; q = params[FIPS186.DSA_PARAMS_Q]; p = params[FIPS186.DSA_PARAMS_P]; e = ...
public KeyPair generate() { if (p == null) { BigInteger[] params = new FIPS186(L, rnd).generateParameters(); seed = params[FIPS186.DSA_PARAMS_SEED]; counter = params[FIPS186.DSA_PARAMS_COUNTER]; q = params[FIPS186.DSA_PARAMS_Q]; p = params[FIPS186.DSA_PARAMS_P]; e = ...
7,727
public void actionPerformed(ActionEvent event) { JTextComponent t = getTextComponent(event); try { if (t != null) { Caret c = t.getCaret(); int x = c.getMagicCaretPosition().x; int pos = Utilities.getPositionAbove(t, ...
public void actionPerformed(ActionEvent event) { JTextComponent t = getTextComponent(event); try { if (t != null) { Caret c = t.getCaret(); Point mcp = c.getMagicCaretPosition(); int x = (mcp != null) ? mcp.x : 0; int...
7,729
public void actionPerformed(ActionEvent event) { JTextComponent t = getTextComponent(event); try { if (t != null) { Caret c = t.getCaret(); int x = c.getMagicCaretPosition().x; int pos = Utilities.getPositionBelow(t, ...
public void actionPerformed(ActionEvent event) { JTextComponent t = getTextComponent(event); try { if (t != null) { Caret c = t.getCaret(); Point mcp = c.getMagicCaretPosition(); int x = (mcp != null) ? mcp.x : 0; int...
7,730
public void actionPerformed(ActionEvent event) { JTextComponent t = getTextComponent(event); try { if (t != null) { Caret c = t.getCaret(); int x = c.getMagicCaretPosition().x; int pos = Utilities.getPositionAbove(t, ...
public void actionPerformed(ActionEvent event) { JTextComponent t = getTextComponent(event); try { if (t != null) { Caret c = t.getCaret(); Point mcp = c.getMagicCaretPosition(); int x = (mcp != null) ? mcp.x : 0; int...
7,731
public void actionPerformed(ActionEvent event) { JTextComponent t = getTextComponent(event); try { if (t != null) { Caret c = t.getCaret(); int x = c.getMagicCaretPosition().x; int pos = Utilities.getPositionBelow(t, ...
public void actionPerformed(ActionEvent event) { JTextComponent t = getTextComponent(event); try { if (t != null) { Caret c = t.getCaret(); Point mcp = c.getMagicCaretPosition(); int x = (mcp != null) ? mcp.x : 0; int...
7,732
public void actionPerformed(ActionEvent event) { JTextComponent t = getTextComponent(event); if (t != null) { int offs = t.getCaretPosition() - 1; if(offs > 0) { Caret c = t.getCaret(); c.moveDot(offs); try { c.setM...
public void actionPerformed(ActionEvent event) { JTextComponent t = getTextComponent(event); if (t != null) { int offs = t.getCaretPosition() - 1; if(offs >= 0) { Caret c = t.getCaret(); c.moveDot(offs); try { c.set...
7,733
public void installUI(JComponent c) { super.installUI(c); if (c instanceof JScrollBar) { scrollbar = (JScrollBar) c; trackRect = new Rectangle(); thumbRect = new Rectangle(); scrollTimer = new Timer(200, null); scrollTimer.setRepeats(true); installComponents(); installDefaults(); configureScrollBarColors(...
public void installUI(JComponent c) { super.installUI(c); if (c instanceof JScrollBar) { scrollbar = (JScrollBar) c; trackRect = new Rectangle(); thumbRect = new Rectangle(); scrollTimer = new Timer(50, null); scrollTimer.setRepeats(true); installComponents(); installDefaults(); configureScrollBarColors()...
7,734
protected void changeState(int stateflag, boolean b) { int oldstate = stateMask; int newstate; if (b) newstate = oldstate | stateflag; else newstate = oldstate & ~ stateflag; if (oldstate == newstate) return; if ((stateflag != SELECTED) && (stateflag != ENABLED) && (stateMas...
private void changeState(int stateflag, boolean b) { int oldstate = stateMask; int newstate; if (b) newstate = oldstate | stateflag; else newstate = oldstate & ~ stateflag; if (oldstate == newstate) return; if ((stateflag != SELECTED) && (stateflag != ENABLED) && (stateMask ...
7,736
public void fireActionPerformed(ActionEvent e) { ActionListener[] ll = getActionListeners(); for (int i = 0; i < ll.length; i++) ll[i].actionPerformed(e); }
protected void fireActionPerformed(ActionEvent e) { ActionListener[] ll = getActionListeners(); for (int i = 0; i < ll.length; i++) ll[i].actionPerformed(e); }
7,737
public void fireItemStateChanged(ItemEvent e) { ItemListener[] ll = getItemListeners(); for (int i = 0; i < ll.length; i++) ll[i].itemStateChanged(e); }
protected void fireItemStateChanged(ItemEvent e) { ItemListener[] ll = getItemListeners(); for (int i = 0; i < ll.length; i++) ll[i].itemStateChanged(e); }
7,738
public void fireStateChanged() { ChangeListener[] ll = getChangeListeners(); for (int i = 0; i < ll.length; i++) ll[i].stateChanged(changeEvent); }
protected void fireStateChanged() { ChangeListener[] ll = getChangeListeners(); for (int i = 0; i < ll.length; i++) ll[i].stateChanged(changeEvent); }
7,739
public BinaryQuad(int address, IRBasicBlock block, int lhsIndex, int varIndex1, int operation, int varIndex2) { super(address, block, lhsIndex); this.operand1 = getOperand(varIndex1); this.operation = operation; this.operand2 = getOperand(varIndex2); refs = new Operand[] { operand1, operand2 }; this.commutative...
public BinaryQuad(int address, IRBasicBlock block, int lhsIndex, int varIndex1, int operation, int varIndex2) { super(address, block, lhsIndex); this.operation = operation; this.operand2 = getOperand(varIndex2); refs = new Operand[] { operand1, operand2 }; this.commutative = operation == IADD || operation ==...
7,740
public BinaryQuad(int address, IRBasicBlock block, int lhsIndex, int varIndex1, int operation, int varIndex2) { super(address, block, lhsIndex); this.operand1 = getOperand(varIndex1); this.operation = operation; this.operand2 = getOperand(varIndex2); refs = new Operand[] { operand1, operand2 }; this.commutative...
public BinaryQuad(int address, IRBasicBlock block, int lhsIndex, int varIndex1, int operation, int varIndex2) { super(address, block, lhsIndex); this.operand1 = getOperand(varIndex1); this.operation = operation; this.operand2 = getOperand(varIndex2); refs = new Operand[] { operand1, operand2 }; this.commutative...
7,741
public void doPass2(BootableHashMap liveVariables) { operand1 = operand1.simplify(); operand2 = operand2.simplify(); if (operand1 instanceof Variable) { Variable v = (Variable) operand1; v.setLastUseAddress(this.getAddress()); liveVariables.put(v, v); } if (operand2 instanceof Variable) { Variable v = (Va...
public void doPass2(BootableHashMap liveVariables) { operand1 = operand1.simplify(); operand2 = operand2.simplify(); if (operand1 instanceof Variable) { Variable v = (Variable) operand1; v.setLastUseAddress(this.getAddress()); liveVariables.put(v, v); } if (operand2 instanceof Variable) { Variable v = (Va...
7,742
public void doPass2(BootableHashMap liveVariables) { operand1 = operand1.simplify(); operand2 = operand2.simplify(); if (operand1 instanceof Variable) { Variable v = (Variable) operand1; v.setLastUseAddress(this.getAddress()); liveVariables.put(v, v); } if (operand2 instanceof Variable) { Variable v = (Va...
public void doPass2(BootableHashMap liveVariables) { operand1 = operand1.simplify(); operand2 = operand2.simplify(); if (operand1 instanceof Variable) { Variable v = (Variable) operand1; v.setLastUseAddress(this.getAddress()); liveVariables.put(v, v); } if (operand2 instanceof Variable) { Variable v = (Va...
7,743
public Quad foldConstants() { if (operand1 instanceof Constant && operand2 instanceof Constant) { Constant c1 = (Constant) operand1; Constant c2 = (Constant) operand2; switch (operation) { case IADD: return new ConstantRefAssignQuad(this.getAddress(), this.getBasicBlock(), this.getLHS().getIndex(), ...
public Quad foldConstants() { if (operand1 instanceof Constant && operand2 instanceof Constant) { Constant c1 = (Constant) operand1; Constant c2 = (Constant) operand2; switch (operation) { case IADD: return new ConstantRefAssignQuad(this.getAddress(), this.getBasicBlock(), this.getLHS().getIndex(), ...
7,744
public void generateCode(CodeGenerator cg) { cg.checkLabel(getAddress()); Variable lhs = getLHS(); int lhsMode = lhs.getAddressingMode(); int op1Mode = operand1.getAddressingMode(); int op2Mode = operand2.getAddressingMode(); Object reg1 = null; if (lhsMode == Operand.MODE_REGISTER) { RegisterLocation r...
public void generateCode(CodeGenerator cg) { cg.checkLabel(getAddress()); Variable lhs = getLHS(); int lhsMode = lhs.getAddressingMode(); int op1Mode = operand1.getAddressingMode(); int op2Mode = operand2.getAddressingMode(); Object reg1 = null; if (lhsMode == Operand.MODE_REGISTER) { RegisterLocation r...
7,745
public void generateCode(CodeGenerator cg) { cg.checkLabel(getAddress()); Variable lhs = getLHS(); int lhsMode = lhs.getAddressingMode(); int op1Mode = operand1.getAddressingMode(); int op2Mode = operand2.getAddressingMode(); Object reg1 = null; if (lhsMode == Operand.MODE_REGISTER) { RegisterLocation r...
public void generateCode(CodeGenerator cg) { cg.checkLabel(getAddress()); Variable lhs = getLHS(); int lhsMode = lhs.getAddressingMode(); int op1Mode = operand1.getAddressingMode(); int op2Mode = operand2.getAddressingMode(); Object reg1 = null; if (lhsMode == Operand.MODE_REGISTER) { RegisterLocation r...
7,746
public void generateCode(CodeGenerator cg) { cg.checkLabel(getAddress()); Variable lhs = getLHS(); int lhsMode = lhs.getAddressingMode(); int op1Mode = operand1.getAddressingMode(); int op2Mode = operand2.getAddressingMode(); Object reg1 = null; if (lhsMode == Operand.MODE_REGISTER) { RegisterLocation r...
public void generateCode(CodeGenerator cg) { cg.checkLabel(getAddress()); Variable lhs = getLHS(); int lhsMode = lhs.getAddressingMode(); int op1Mode = operand1.getAddressingMode(); int op2Mode = operand2.getAddressingMode(); Object reg1 = null; if (lhsMode == Operand.MODE_REGISTER) { RegisterLocation r...
7,747
public void generateCode(CodeGenerator cg) { cg.checkLabel(getAddress()); Variable lhs = getLHS(); int lhsMode = lhs.getAddressingMode(); int op1Mode = operand1.getAddressingMode(); int op2Mode = operand2.getAddressingMode(); Object reg1 = null; if (lhsMode == Operand.MODE_REGISTER) { RegisterLocation r...
public void generateCode(CodeGenerator cg) { cg.checkLabel(getAddress()); Variable lhs = getLHS(); int lhsMode = lhs.getAddressingMode(); int op1Mode = operand1.getAddressingMode(); int op2Mode = operand2.getAddressingMode(); Object reg1 = null; if (lhsMode == Operand.MODE_REGISTER) { RegisterLocation r...
7,748
public void generateCode(CodeGenerator cg) { cg.checkLabel(getAddress()); Variable lhs = getLHS(); int lhsMode = lhs.getAddressingMode(); int op1Mode = operand1.getAddressingMode(); int op2Mode = operand2.getAddressingMode(); Object reg1 = null; if (lhsMode == Operand.MODE_REGISTER) { RegisterLocation r...
public void generateCode(CodeGenerator cg) { cg.checkLabel(getAddress()); Variable lhs = getLHS(); int lhsMode = lhs.getAddressingMode(); int op1Mode = operand1.getAddressingMode(); int op2Mode = operand2.getAddressingMode(); Object reg1 = null; if (lhsMode == Operand.MODE_REGISTER) { RegisterLocation r...
7,749
public String toString() { return getAddress() + ": " + getLHS().toString() + " = " + operand1.toString() + " " + OP_MAP[operation - IADD] + " " + operand2.toString(); }
public String toString() { return getAddress() + ": " + getLHS().toString() + " = " + operand1.toString() + " " + OP_MAP[operation - IADD] + " " + operand2.toString(); }
7,750
private void addDataToCurrentArray ( Locator dataLocator, String thisString, DataFormat CurrentDataFormat, int intRadix ) {/*// this stuff slows down t...
private void addDataToCurrentArray ( Locator dataLocator, String thisString, DataFormat CurrentDataFormat, int intRadix ) {/*// this stuff slows down t...
7,752
public String getProperty(String key, String def) { return def; }
public String getProperty(String key, String def) { if (settings.containsKey(key)) return settings.getProperty(key); else return def; }
7,756
public MediaPrintableArea(float x, float y, float w, float h, int units) { if (x < 0.0f || y < 0.0f || w <= 0.0f || h <= 0.0f) throw new IllegalArgumentException(); this.x = x; this.y = y; this.width = w; this.height = h; }
public MediaPrintableArea(float x, float y, float w, float h, int units) { if (x < 0.0f || y < 0.0f || w <= 0.0f || h <= 0.0f) throw new IllegalArgumentException(); this.x = x; this.y = y; this.width = w; this.height = h; }
7,758
public float getHeight(int units) { if (units < 1) throw new IllegalArgumentException(); return height * units; }
public float getHeight(int units) { if (units < 1) throw new IllegalArgumentException("units may not be less than 1"); return height * units; }
7,759
public float getHeight(int units) { if (units < 1) throw new IllegalArgumentException(); return height * units; }
public float getHeight(int units) { if (units < 1) throw new IllegalArgumentException(); return height / ((float)units); }
7,760
public float getWidth(int units) { if (units < 1) throw new IllegalArgumentException(); return width * units; }
public float getWidth(int units) { if (units < 1) throw new IllegalArgumentException("units may not be less than 1"); return width * units; }
7,761
public float getWidth(int units) { if (units < 1) throw new IllegalArgumentException(); return width * units; }
public float getWidth(int units) { if (units < 1) throw new IllegalArgumentException(); return width / ((float)units); }
7,762
public float getX(int units) { if (units < 1) throw new IllegalArgumentException(); return x * units; }
public float getX(int units) { if (units < 1) throw new IllegalArgumentException("units may not be less than 1"); return x * units; }
7,763