bugged stringlengths 6 599k | fixed stringlengths 10 599k | __index_level_0__ int64 0 1.13M |
|---|---|---|
public static void initialize() { if (!inited) { // Initialize resource manager final ResourceManager rm = ResourceManagerImpl.initialize(); VmSystem.out = getSystemOut(); /* Initialize the system classloader */ VmSystemClassLoader loader = (VmSystemClas... | public static void initialize() { if (!inited) { // Initialize resource manager final ResourceManager rm = ResourceManagerImpl.initialize(); VmSystem.out = getSystemOut(); /* Initialize the system classloader */ VmSystemClassLoader loader = (VmSystemClas... | 12,607 |
static public List<String> getEntryNames(Iterator<FSEntry> it) { List<String> names = new ArrayList<String>(); while (it.hasNext()) { FSEntry entry = it.next(); names.add((entry == null) ? null : entry.getName()); } return names; } | static public List<String> getEntryNames(Iterator<? extends FSEntry> it) { List<String> names = new ArrayList<String>(); while (it.hasNext()) { FSEntry entry = it.next(); names.add((entry == null) ? null : entry.getName()); } return names; } | 12,608 |
static public void listEntries(Iterator<FSEntry> iterator) throws Exception { log.debug("<<< BEGIN listEntries >>>"); int i = 0; log.debug("------- entries ------"); while (iterator.hasNext()) { FSEntry entry = iterator.next(); log.debug(i + ":" + entry); ... | static public void listEntries(Iterator<? extends FSEntry> iterator) throws Exception { log.debug("<<< BEGIN listEntries >>>"); int i = 0; log.debug("------- entries ------"); while (iterator.hasNext()) { FSEntry entry = iterator.next(); log.debug(i + ":" + entry); ... | 12,609 |
static public String toString(List<String> list) { StringBuffer sb = new StringBuffer("["); for (int i = 0; i < list.size(); i++) { if (i > 0) { sb.append(", "); } sb.append(list.get(i)); } sb.append("]"); return sb.toString(); } | static public String toString(List<String> list) { StringBuffer sb = new StringBuffer("["); for (int i = 0; i < list.size(); i++) { if (i > 0) { sb.append(", "); } sb.append(list.get(i)); } sb.append("]"); return sb.toString(); } | 12,610 |
public void addActionListener(ActionListener l) { // comp.enableEvents( AWTEvent.ACTION_EVENT_MASK ); actions.addElement(l); } | public void addActionListener(ActionListener l) { // comp.enableEvents( AWTEvent.ACTION_EVENT_MASK ); actions.addElement(l); } | 12,612 |
public void addChangeListener(ChangeListener l) { changes.addElement(l); } | public void addChangeListener(ChangeListener l) { changes.addElement(l); } | 12,613 |
public void addItemListener(ItemListener l) { items.addElement(l); } | public void addItemListener(ItemListener l) { items.addElement(l); } | 12,614 |
public void fireItemStateChanged(ItemEvent event) { for (int i = 0; i < items.size(); i++) { ItemListener a = (ItemListener) items.get(i); a.itemStateChanged(event); } } | public void fireItemStateChanged(ItemEvent event) { for (int i = 0; i < items.size(); i++) { ItemListener a = (ItemListener) items.get(i); a.itemStateChanged(event); } } | 12,615 |
public void fireStateChanged(ChangeEvent event) { for (int i = 0; i < changes.size(); i++) { ChangeListener a = (ChangeListener) changes.get(i); a.stateChanged(event); } } | public void fireStateChanged(ChangeEvent event) { for (int i = 0; i < changes.size(); i++) { ChangeListener a = (ChangeListener) changes.get(i); a.stateChanged(event); } } | 12,616 |
public String getActionCommand() { return com; } | public String getActionCommand() { return com; } | 12,617 |
public int getMnemonic() { return mne; } | public int getMnemonic() { return mne; } | 12,618 |
public boolean isRollover() { return roll; } | public boolean isRollover() { return roll; } | 12,619 |
public void removeActionListener(ActionListener l) { actions.removeElement(l); } | public void removeActionListener(ActionListener l) { actions.removeElement(l); } | 12,620 |
public void removeChangeListener(ChangeListener l) { changes.removeElement(l); } | public void removeChangeListener(ChangeListener l) { changes.removeElement(l); } | 12,621 |
public void removeItemListener(ItemListener l) { items.removeElement(l); } | public void removeItemListener(ItemListener l) { items.removeElement(l); } | 12,622 |
public void setActionCommand(String s) { com = s; } | public void setActionCommand(String s) { com = s; } | 12,623 |
public void setArmed(boolean b) { arm = b; } | public void setArmed(boolean b) { arm = b; } | 12,624 |
public void setEnabled(boolean b) { enabled = b; } | public void setEnabled(boolean b) { enabled = b; } | 12,625 |
public void setGroup(ButtonGroup group) { this.group = group; } | public void setGroup(ButtonGroup group) { this.group = group; } | 12,626 |
public void setMnemonic(int key) { mne = key; } | public void setMnemonic(int key) { mne = key; } | 12,627 |
public void setRollover(boolean b) { roll = b; } | public void setRollover(boolean b) { roll = b; } | 12,628 |
public final void visit_iinc(int index, int incValue) { vstack.loadLocal(eContext, index); // avoid aliasing throubles final int ebpOfs = stackFrame.getEbpOffset(index); X86RegisterPool pool = eContext.getPool(); final Register r = (Register)pool.request(Item.INT); //IMPROVE: use ... | public final void visit_iinc(int index, int incValue) { final int ebpOfs = stackFrame.getEbpOffset(index); // avoid aliasing throubles final int ebpOfs = stackFrame.getEbpOffset(index); X86RegisterPool pool = eContext.getPool(); final Register r = (Register)pool.request(Item.INT); ... | 12,632 |
public final void visit_iinc(int index, int incValue) { vstack.loadLocal(eContext, index); // avoid aliasing throubles final int ebpOfs = stackFrame.getEbpOffset(index); X86RegisterPool pool = eContext.getPool(); final Register r = (Register)pool.request(Item.INT); //IMPROVE: use ... | public final void visit_iinc(int index, int incValue) { vstack.loadLocal(eContext, index); // avoid aliasing throubles vstack.loadLocal(eContext, ebpOfs); X86RegisterPool pool = eContext.getPool(); final Register r = (Register)pool.request(Item.INT); //IMPROVE: use INC or ADD reg,... | 12,633 |
public void emitTrailer(int maxLocals) { final int argSlotCount = method.getArgSlotCount(); final Label stackOverflowLabel = helper.genLabel("$$stack-overflow"); // Begin footer // Now start the actual footer os.setObjectRef(footerLabel); /* Go restore the previous current frame */ emitSynchronizationCode(conte... | public void emitTrailer(int maxLocals) { final int argSlotCount = method.getArgSlotCount(); final Label stackOverflowLabel = helper.genLabel("$$stack-overflow"); // Begin footer // Now start the actual footer os.setObjectRef(footerLabel); /* Go restore the previous current frame */ emitSynchronizationCode(conte... | 12,636 |
public void startInlinedMethod(VmMethod inlinedMethod, Label curInstrLabel) { this.labelPrefix = curInstrLabel + "_" + inlinedMethod + "_"; this.instrLabelPrefix = labelPrefix + "_bci_"; this.addressLabels.clear(); } | public void startInlinedMethod(VmMethod inlinedMethod, Label curInstrLabel) { this.labelPrefix = curInstrLabel + "_" + inlinedMethod.getName() + "_"; this.instrLabelPrefix = labelPrefix + "_bci_"; this.addressLabels.clear(); } | 12,637 |
void loadLocal(EmitterContext ec, int index) { for (int i = 0; i < tos; i++) { final Item item = stack[i]; if ((item.getKind() == Item.LOCAL) && (item.getOffsetToFP() == index)) item.load(ec); } } | void loadLocal(EmitterContext ec, int offsetToFP) { for (int i = 0; i < tos; i++) { final Item item = stack[i]; if ((item.getKind() == Item.LOCAL) && (item.getOffsetToFP() == index)) item.load(ec); } } | 12,638 |
void loadLocal(EmitterContext ec, int index) { for (int i = 0; i < tos; i++) { final Item item = stack[i]; if ((item.getKind() == Item.LOCAL) && (item.getOffsetToFP() == index)) item.load(ec); } } | void loadLocal(EmitterContext ec, int index) { for (int i = 0; i < tos; i++) { final Item item = stack[i]; if ((item.getKind() == Item.LOCAL) && (item.getOffsetToFP() == offsetToFP)) item.load(ec); } } | 12,639 |
protected void initComponentDefaults(UIDefaults defaults) { Object[] uiDefaults; // The default Look and Feel happens to use these three purple shades // extensively. Color lightPurple = new Color(0xCC, 0xCC, 0xFF); Color midPurple = new Color(0x99, 0x99, 0xCC); Color darkPurple = new Color(0x6... | protected void initComponentDefaults(UIDefaults defaults) { Object[] uiDefaults; // The default Look and Feel happens to use these three purple shades // extensively. Color lightPurple = new Color(0xCC, 0xCC, 0xFF); Color midPurple = new Color(0x99, 0x99, 0xCC); Color darkPurple = new Color(0x6... | 12,640 |
public static Border getEtchedBorderUIResource() { return null; } | public static Border getEtchedBorderUIResource() { return null; } | 12,641 |
public static ComponentUI createUI(JComponent component) { if (instances == null) instances = new HashMap(); Object o = instances.get(component); MetalTreeUI instance; if (o == null) { instance = new MetalTreeUI(); instances.put(component, instance); } else instance =... | public static ComponentUI createUI(JComponent component) { if (instances == null) instances = new HashMap(); Object o = instances.get(component); MetalTreeUI instance; if (o == null) { instance = new MetalTreeUI(); instances.put(component, instance); } else instance =... | 12,642 |
public final void copy(Address src, Address dst, int size) { Unsafe.copy(src, dst, size); } | public final void copy(Address src, Address dst, Extent size) { Unsafe.copy(src, dst, size); } | 12,643 |
public MappedFSBlockDeviceSupport(Device parent, long offset, long length) throws IOException { super(parent, offset, length); try { this.parentApi = (FSBlockDeviceAPI) parent.getAPI(FSBlockDeviceAPI.class); } catch (ApiNotFoundException ex) { throw new IOExcept... | public MappedFSBlockDeviceSupport(Device parent, long offset, long length) throws IOException { super(parent, offset, length); try { this.parentApi = (FSBlockDeviceAPI) parent.getAPI(FSBlockDeviceAPI.class); } catch (ApiNotFoundException ex) { final IOException ... | 12,644 |
public Iterator iterator() { return new IndexEntryIterator(parentFileRecord, this, getHeader() .getFirstEntryOffset() + 0x18); } | public Iterator<IndexEntry> iterator() { return new IndexEntryIterator(parentFileRecord, this, getHeader() .getFirstEntryOffset() + 0x18); } | 12,645 |
public MarshalException(String s, Exception e) { super(s, e); } | public MarshalException(String s) { super(s, e); } | 12,646 |
public MarshalException(String s, Exception e) { super(s, e); } | public MarshalException(String s, Exception e) { super(s); } | 12,647 |
private void copyIso8859_1ReadBuffer (int count, char mask) throws IOException { int i, j; for (i = 0, j = readBufferPos; i < count; i++, j++) { char c = (char) (rawReadBuffer [i] & 0xff); if ((c & mask) != 0) throw new CharConversionException ("non-ASCII character U+" + Integer.toHexString ... | private void copyIso8859_1ReadBuffer (int count, char mask) throws IOException { int i, j; for (i = 0, j = readBufferPos; i < count; i++, j++) { char c = (char) (rawReadBuffer [i] & 0xff); if ((c & mask) != 0) throw new CharConversionException ("non-ASCII character U+" + Integer.toHexString ... | 12,650 |
private void copyIso8859_1ReadBuffer (int count, char mask) throws IOException { int i, j; for (i = 0, j = readBufferPos; i < count; i++, j++) { char c = (char) (rawReadBuffer [i] & 0xff); if ((c & mask) != 0) throw new CharConversionException ("non-ASCII character U+" + Integer.toHexString ... | private void copyIso8859_1ReadBuffer (int count, char mask) throws IOException { int i, j; for (i = 0, j = readBufferPos; i < count; i++, j++) { char c = (char) (rawReadBuffer [i] & 0xff); if ((c & mask) != 0) throw new CharConversionException ("non-ASCII character U+" + Integer.toHexString ... | 12,651 |
private void copyUcs2ReadBuffer (int count, int shift1, int shift2) throws SAXException { int j = readBufferPos; if (count > 0 && (count % 2) != 0) { encodingError ("odd number of bytes in UCS-2 encoding", -1, count); } // The loops are faster with less internal brancing; hence two if (shift1 == 0) { // "... | private void copyUcs2ReadBuffer (int count, int shift1, int shift2) throws SAXException { int j = readBufferPos; if (count > 0 && (count % 2) != 0) { encodingError ("odd number of bytes in UCS-2 encoding", -1, count); } // The loops are faster with less internal brancing; hence two if (shift1 == 0) { // "... | 12,652 |
private void copyUcs4ReadBuffer (int count, int shift1, int shift2, int shift3, int shift4) throws SAXException { int j = readBufferPos; if (count > 0 && (count % 4) != 0) { encodingError ( "number of bytes in UCS-4 encoding not divisible by 4", -1, count); } for (int i = 0; i < count; i... | private void copyUcs4ReadBuffer (int count, int shift1, int shift2, int shift3, int shift4) throws SAXException { int j = readBufferPos; if (count > 0 && (count % 4) != 0) { encodingError ( "number of bytes in UCS-4 encoding not divisible by 4", -1, count); } for (int i = 0; i < count; i... | 12,654 |
private void copyUtf8ReadBuffer (int count) throws SAXException, IOException { int i = 0; int j = readBufferPos; int b1; char c = 0; /* // check once, so the runtime won't (if it's smart enough) if (count < 0 || count > rawReadBuffer.length) throw new ArrayIndexOutOfBoundsException (Integer.toString (coun... | private void copyUtf8ReadBuffer (int count) throws SAXException, IOException { int i = 0; int j = readBufferPos; int b1; char c = 0; /* // check once, so the runtime won't (if it's smart enough) if (count < 0 || count > rawReadBuffer.length) throw new ArrayIndexOutOfBoundsException (Integer.toString (coun... | 12,655 |
private void copyUtf8ReadBuffer (int count) throws SAXException, IOException { int i = 0; int j = readBufferPos; int b1; char c = 0; /* // check once, so the runtime won't (if it's smart enough) if (count < 0 || count > rawReadBuffer.length) throw new ArrayIndexOutOfBoundsException (Integer.toString (coun... | private void copyUtf8ReadBuffer (int count) throws SAXException, IOException { int i = 0; int j = readBufferPos; int b1; char c = 0; /* // check once, so the runtime won't (if it's smart enough) if (count < 0 || count > rawReadBuffer.length) throw new ArrayIndexOutOfBoundsException (Integer.toString (coun... | 12,656 |
private void copyUtf8ReadBuffer (int count) throws SAXException, IOException { int i = 0; int j = readBufferPos; int b1; char c = 0; /* // check once, so the runtime won't (if it's smart enough) if (count < 0 || count > rawReadBuffer.length) throw new ArrayIndexOutOfBoundsException (Integer.toString (coun... | private void copyUtf8ReadBuffer (int count) throws SAXException, IOException { int i = 0; int j = readBufferPos; int b1; char c = 0; /* // check once, so the runtime won't (if it's smart enough) if (count < 0 || count > rawReadBuffer.length) throw new ArrayIndexOutOfBoundsException (Integer.toString (coun... | 12,657 |
private void copyUtf8ReadBuffer (int count) throws SAXException, IOException { int i = 0; int j = readBufferPos; int b1; char c = 0; /* // check once, so the runtime won't (if it's smart enough) if (count < 0 || count > rawReadBuffer.length) throw new ArrayIndexOutOfBoundsException (Integer.toString (coun... | private void copyUtf8ReadBuffer (int count) throws SAXException, IOException { int i = 0; int j = readBufferPos; int b1; char c = 0; /* // check once, so the runtime won't (if it's smart enough) if (count < 0 || count > rawReadBuffer.length) throw new ArrayIndexOutOfBoundsException (Integer.toString (coun... | 12,658 |
private void copyUtf8ReadBuffer (int count) throws SAXException, IOException { int i = 0; int j = readBufferPos; int b1; char c = 0; /* // check once, so the runtime won't (if it's smart enough) if (count < 0 || count > rawReadBuffer.length) throw new ArrayIndexOutOfBoundsException (Integer.toString (coun... | private void copyUtf8ReadBuffer (int count) throws SAXException, IOException { int i = 0; int j = readBufferPos; int b1; char c = 0; /* // check once, so the runtime won't (if it's smart enough) if (count < 0 || count > rawReadBuffer.length) throw new ArrayIndexOutOfBoundsException (Integer.toString (coun... | 12,659 |
private void copyUtf8ReadBuffer (int count) throws SAXException, IOException { int i = 0; int j = readBufferPos; int b1; char c = 0; /* // check once, so the runtime won't (if it's smart enough) if (count < 0 || count > rawReadBuffer.length) throw new ArrayIndexOutOfBoundsException (Integer.toString (coun... | private void copyUtf8ReadBuffer (int count) throws SAXException, IOException { int i = 0; int j = readBufferPos; int b1; char c = 0; /* // check once, so the runtime won't (if it's smart enough) if (count < 0 || count > rawReadBuffer.length) throw new ArrayIndexOutOfBoundsException (Integer.toString (coun... | 12,660 |
private void dataBufferAppend (char c) { // Expand buffer if necessary. if (dataBufferPos >= dataBuffer.length) dataBuffer = (char[]) extendArray (dataBuffer, dataBuffer.length, dataBufferPos); dataBuffer [dataBufferPos++] = c; } | private void dataBufferAppend (char c) { // Expand buffer if necessary. if (dataBufferPos >= dataBuffer.length) dataBuffer = (char[]) extendArray (dataBuffer, dataBuffer.length, dataBufferPos); dataBuffer [dataBufferPos++] = c; } | 12,662 |
private void dataBufferAppend (char c) { // Expand buffer if necessary. if (dataBufferPos >= dataBuffer.length) dataBuffer = (char[]) extendArray (dataBuffer, dataBuffer.length, dataBufferPos); dataBuffer [dataBufferPos++] = c; } | private void dataBufferAppend (char c) { // Expand buffer if necessary. if (dataBufferPos >= dataBuffer.length) dataBuffer = (char[]) extendArray (dataBuffer, dataBuffer.length, dataBufferPos); } | 12,663 |
private void dataBufferNormalize () { int i = 0; int j = 0; int end = dataBufferPos; // Skip spaces at the start. while (j < end && dataBuffer [j] == ' ') { j++; } // Skip whitespace at the end. while (end > j && dataBuffer [end - 1] == ' ') { end --; } // Start copying to the left. while (j < end) { ... | private void dataBufferNormalize () { int i = 0; int j = 0; int end = dataBufferPos; // Skip spaces at the start. while (j < end && dataBuffer [j] == ' ') { j++; } // Skip whitespace at the end. while (end > j && dataBuffer [end - 1] == ' ') { end --; } // Start copying to the left. while (j < end) { ... | 12,665 |
private void dataBufferNormalize () { int i = 0; int j = 0; int end = dataBufferPos; // Skip spaces at the start. while (j < end && dataBuffer [j] == ' ') { j++; } // Skip whitespace at the end. while (end > j && dataBuffer [end - 1] == ' ') { end --; } // Start copying to the left. while (j < end) { ... | private void dataBufferNormalize () { int i = 0; int j = 0; int end = dataBufferPos; // Skip spaces at the start. while (j < end && dataBuffer [j] == ' ') { j++; } // Skip whitespace at the end. while (end > j && dataBuffer [end - 1] == ' ') { end --; } // Start copying to the left. while (j < end) { ... | 12,666 |
private Enumeration declaredAttributes (Object element []) { Hashtable attlist; if (element == null) return null; if ((attlist = (Hashtable) element [2]) == null) return null; return attlist.keys (); } | private Iterator declaredAttributes(ElementDecl element) { Hashtable attlist; if (element == null) return null; if ((attlist = (Hashtable) element [2]) == null) return null; return attlist.keys (); } | 12,667 |
private Enumeration declaredAttributes (Object element []) { Hashtable attlist; if (element == null) return null; if ((attlist = (Hashtable) element [2]) == null) return null; return attlist.keys (); } | private Enumeration declaredAttributes (Object element []) { HashMap attlist; if (element == null) return null; if ((attlist = (Hashtable) element [2]) == null) return null; return attlist.keys (); } | 12,668 |
private Enumeration declaredAttributes (Object element []) { Hashtable attlist; if (element == null) return null; if ((attlist = (Hashtable) element [2]) == null) return null; return attlist.keys (); } | private Enumeration declaredAttributes (Object element []) { Hashtable attlist; if (element == null) return null; } if ((attlist = element.attributes) == null) { return null; return attlist.keys (); } | 12,669 |
private Enumeration declaredAttributes (Object element []) { Hashtable attlist; if (element == null) return null; if ((attlist = (Hashtable) element [2]) == null) return null; return attlist.keys (); } | private Enumeration declaredAttributes (Object element []) { Hashtable attlist; if (element == null) return null; if ((attlist = (Hashtable) element [2]) == null) return null; } return attlist.keySet().iterator(); } | 12,670 |
private void detectEncoding () throws SAXException, IOException { byte signature[] = new byte [4]; // Read the first four bytes for // autodetection. is.mark (4); is.read (signature); is.reset (); // // FIRST: four byte encodings (who uses these?) // if (tryEncoding (signature, (byte) 0x00, (byte) 0x00, ... | private void detectEncoding () throws SAXException, IOException { byte[] signature = new byte[4]; // Read the first four bytes for // autodetection. is.mark (4); is.read (signature); is.reset (); // // FIRST: four byte encodings (who uses these?) // if (tryEncoding (signature, (byte) 0x00, (byte) 0x00, (... | 12,671 |
private void encodingError (String message, int value, int offset) throws SAXException { if (value != -1) message = message + " (character code: 0x" + Integer.toHexString (value) + ')'; error (message); } | private void encodingError (String message, int value, int offset) throws SAXException { if (value != -1) message = message + " (character code: 0x" + Integer.toHexString (value) + ')'; error (message); } | 12,672 |
private Object extendArray (Object array, int currentSize, int requiredSize) { if (requiredSize < currentSize) { return array; } else { Object newArray = null; int newSize = currentSize * 2; if (newSize <= requiredSize) newSize = requiredSize + 1; if (array instanceof char[]) newArray = new... | private Object extendArray(Object array, int currentSize, int requiredSize) { if (requiredSize < currentSize) { if (requiredSize < currentSize) { return array; } else { Object newArray = null; int newSize = currentSize * 2; if (newSize <= requiredSize) newSize = requiredSize + 1; if (array i... | 12,673 |
private Object extendArray (Object array, int currentSize, int requiredSize) { if (requiredSize < currentSize) { return array; } else { Object newArray = null; int newSize = currentSize * 2; if (newSize <= requiredSize) newSize = requiredSize + 1; if (array instanceof char[]) newArray = new... | private Object extendArray (Object array, int currentSize, int requiredSize) { return array; } else { Object newArray = null; int newSize = currentSize * 2; if (newSize <= requiredSize) newSize = requiredSize + 1; if (array instanceof char[]) newArray = new char [newSize]; else if (arr... | 12,674 |
private Object extendArray (Object array, int currentSize, int requiredSize) { if (requiredSize < currentSize) { return array; } else { Object newArray = null; int newSize = currentSize * 2; if (newSize <= requiredSize) newSize = requiredSize + 1; if (array instanceof char[]) newArray = new... | private Object extendArray (Object array, int currentSize, int requiredSize) { if (requiredSize < currentSize) { return array; } else { Object newArray = null; int newSize = currentSize * 2; if (newSize <= requiredSize) newSize = requiredSize + 1; if (array instanceof char[]) { newArray = n... | 12,675 |
private Object extendArray (Object array, int currentSize, int requiredSize) { if (requiredSize < currentSize) { return array; } else { Object newArray = null; int newSize = currentSize * 2; if (newSize <= requiredSize) newSize = requiredSize + 1; if (array instanceof char[]) newArray = new... | private Object extendArray (Object array, int currentSize, int requiredSize) { if (requiredSize < currentSize) { return array; } else { Object newArray = null; int newSize = currentSize * 2; if (newSize <= requiredSize) newSize = requiredSize + 1; if (array instanceof char[]) newArray = new... | 12,676 |
private Object extendArray (Object array, int currentSize, int requiredSize) { if (requiredSize < currentSize) { return array; } else { Object newArray = null; int newSize = currentSize * 2; if (newSize <= requiredSize) newSize = requiredSize + 1; if (array instanceof char[]) newArray = new... | private Object extendArray (Object array, int currentSize, int requiredSize) { if (requiredSize < currentSize) { return array; } else { Object newArray = null; int newSize = currentSize * 2; if (newSize <= requiredSize) newSize = requiredSize + 1; if (array instanceof char[]) newArray = new... | 12,677 |
private void filterCR (boolean moreData) { int i, j; readBufferOverflow = -1;loop: for (i = j = readBufferPos; j < readBufferLength; i++, j++) { switch (readBuffer [j]) { case '\r': if (j == readBufferLength - 1) { if (moreData) { readBufferOverflow = '\r'; readBufferLength--; } else // C... | private void filterCR (boolean moreData) { int i, j; readBufferOverflow = -1;loop: for (i = j = readBufferPos; j < readBufferLength; i++, j++) { switch (readBuffer [j]) { case '\r': if (j == readBufferLength - 1) { if (moreData) { readBufferOverflow = '\r'; readBufferLength--; } else // C... | 12,678 |
private Object[] getAttribute (String elName, String name) { Hashtable attlist; attlist = getElementAttributes (elName); if (attlist == null) return null; return (Object[]) attlist.get (name); } | private AttributeDecl getAttribute(String elName, String name) { Hashtable attlist; attlist = getElementAttributes (elName); if (attlist == null) return null; return (Object[]) attlist.get (name); } | 12,679 |
private Object[] getAttribute (String elName, String name) { Hashtable attlist; attlist = getElementAttributes (elName); if (attlist == null) return null; return (Object[]) attlist.get (name); } | private Object[] getAttribute (String elName, String name) { Hashtable attlist; attlist = getElementAttributes (elName); if (attlist == null) return null; return (Object[]) attlist.get (name); } | 12,680 |
public String getAttributeDefaultValue (String name, String aname) { Object attribute[] = getAttribute (name, aname); if (attribute == null) { return null; } else { return (String) attribute [1]; } } | public String getAttributeDefaultValue (String name, String aname) { Object attribute[] = getAttribute (name, aname); if (attribute == null) { return null; } else { return (String) attribute [1]; } } | 12,681 |
public int getAttributeDefaultValueType (String name, String aname) { Object attribute[] = getAttribute (name, aname); if (attribute == null) { return ATTRIBUTE_DEFAULT_UNDECLARED; } else { return ((Integer) attribute [2]).intValue (); } } | public int getAttributeDefaultValueType (String name, String aname) { Object attribute[] = getAttribute (name, aname); if (attribute == null) { return ATTRIBUTE_DEFAULT_UNDECLARED; } else { return ((Integer) attribute [2]).intValue (); } } | 12,682 |
public String getAttributeEnumeration (String name, String aname) { Object attribute[] = getAttribute (name, aname); if (attribute == null) { return null; } else { // assert: attribute [0] is "ENUMERATION" or "NOTATION" return (String) attribute [3]; } } | public String getAttributeEnumeration (String name, String aname) { Object attribute[] = getAttribute (name, aname); if (attribute == null) { return null; } else { // assert: attribute [0] is "ENUMERATION" or "NOTATION" return (String) attribute [3]; } } | 12,683 |
private int getContentType (Object element [], int defaultType) { int retval; if (element == null) return defaultType; retval = ((Integer) element [0]).intValue (); if (retval == CONTENT_UNDECLARED) retval = defaultType; return retval; } | private int getContentType(ElementDecl element, int defaultType) { int retval; if (element == null) return defaultType; retval = ((Integer) element [0]).intValue (); if (retval == CONTENT_UNDECLARED) retval = defaultType; return retval; } | 12,684 |
private int getContentType (Object element [], int defaultType) { int retval; if (element == null) return defaultType; retval = ((Integer) element [0]).intValue (); if (retval == CONTENT_UNDECLARED) retval = defaultType; return retval; } | private int getContentType (Object element [], int defaultType) { int retval; if (element == null) return defaultType; } retval = element.contentType; if (retval == CONTENT_UNDECLARED) retval = defaultType; return retval; } | 12,685 |
private Hashtable getElementAttributes (String name) { Object element[] = (Object[]) elementInfo.get (name); if (element == null) return null; else return (Hashtable) element [2]; } | private HashMap getElementAttributes(String name) { Object element[] = (Object[]) elementInfo.get (name); if (element == null) return null; else return (Hashtable) element [2]; } | 12,687 |
private Hashtable getElementAttributes (String name) { Object element[] = (Object[]) elementInfo.get (name); if (element == null) return null; else return (Hashtable) element [2]; } | private Hashtable getElementAttributes (String name) { Object element[] = (Object[]) elementInfo.get (name); if (element == null) return null; else return (Hashtable) element [2]; } | 12,688 |
public int getElementContentType (String name) { Object element [] = (Object []) elementInfo.get (name); return getContentType (element, CONTENT_UNDECLARED); } | public int getElementContentType (String name) { Object element [] = (Object []) elementInfo.get (name); return getContentType (element, CONTENT_UNDECLARED); } | 12,689 |
public String [] getEntityIds (String ename) { Object entity[] = (Object[]) entityInfo.get (ename); if (entity == null) { return null; } else { return (String []) entity [1]; } } | public ExternalIdentifiers getEntityIds(String ename) { Object entity[] = (Object[]) entityInfo.get (ename); if (entity == null) { return null; } else { return (String []) entity [1]; } } | 12,690 |
public String [] getEntityIds (String ename) { Object entity[] = (Object[]) entityInfo.get (ename); if (entity == null) { return null; } else { return (String []) entity [1]; } } | public String [] getEntityIds (String ename) { Object entity[] = (Object[]) entityInfo.get (ename); if (entity == null) { return null; } else { return (String []) entity [1]; } } | 12,691 |
public int getEntityType (String ename) { Object entity[] = (Object[]) entityInfo.get (ename); if (entity == null) { return ENTITY_UNDECLARED; } else { return ((Integer) entity [0]).intValue (); } } | public int getEntityType (String ename) { Object entity[] = (Object[]) entityInfo.get (ename); if (entity == null) { return ENTITY_UNDECLARED; } else { return ((Integer) entity [0]).intValue (); } } | 12,692 |
public int getEntityType (String ename) { Object entity[] = (Object[]) entityInfo.get (ename); if (entity == null) { return ENTITY_UNDECLARED; } else { return ((Integer) entity [0]).intValue (); } } | public int getEntityType (String ename) { Object entity[] = (Object[]) entityInfo.get (ename); if (entity == null) { return ENTITY_UNDECLARED; else { return ((Integer) entity [0]).intValue (); | 12,693 |
public String getEntityValue (String ename) { Object entity[] = (Object[]) entityInfo.get (ename); if (entity == null) { return null; } else { return (String) entity [3]; } } | public String getEntityValue (String ename) { Object entity[] = (Object[]) entityInfo.get (ename); if (entity == null) { return null; } else { return (String) entity [3]; } } | 12,694 |
public String getEntityValue (String ename) { Object entity[] = (Object[]) entityInfo.get (ename); if (entity == null) { return null; } else { return (String) entity [3]; } } | public String getEntityValue (String ename) { Object entity[] = (Object[]) entityInfo.get (ename); if (entity == null) { return null; else { return (String) entity [3]; | 12,695 |
private void initializeVariables () { // First line line = 1; column = 0; // Set up the buffers for data and names dataBufferPos = 0; dataBuffer = new char [DATA_BUFFER_INITIAL]; nameBufferPos = 0; nameBuffer = new char [NAME_BUFFER_INITIAL]; // Set up the DTD hash tables elementInfo = new Hashtable (); entityIn... | private void initializeVariables () { // First line line = 1; column = 0; // Set up the buffers for data and names dataBufferPos = 0; dataBuffer = new char [DATA_BUFFER_INITIAL]; nameBufferPos = 0; nameBuffer = new char [NAME_BUFFER_INITIAL]; // Set up the DTD hash tables elementInfo = new Hashtable (); entityIn... | 12,696 |
private void initializeVariables () { // First line line = 1; column = 0; // Set up the buffers for data and names dataBufferPos = 0; dataBuffer = new char [DATA_BUFFER_INITIAL]; nameBufferPos = 0; nameBuffer = new char [NAME_BUFFER_INITIAL]; // Set up the DTD hash tables elementInfo = new Hashtable (); entityIn... | private void initializeVariables () { // First line line = 1; column = 0; // Set up the buffers for data and names dataBufferPos = 0; dataBuffer = new char [DATA_BUFFER_INITIAL]; nameBufferPos = 0; nameBuffer = new char [NAME_BUFFER_INITIAL]; // Set up the DTD hash tables elementInfo = new Hashtable (); entityIn... | 12,697 |
public String intern (char ch[], int start, int length) { int index = 0; int hash = 0; Object bucket []; // Generate a hash code. This is a widely used string hash, // often attributed to Brian Kernighan. for (int i = start; i < start + length; i++) hash = 31 * hash + ch [i]; hash = (hash & 0x7fffffff) % SY... | public String intern(char[] ch, int start, int length) { int index = 0; int hash = 0; Object bucket []; // Generate a hash code. This is a widely used string hash, // often attributed to Brian Kernighan. for (int i = start; i < start + length; i++) hash = 31 * hash + ch [i]; hash = (hash & 0x7fffffff) % SYM... | 12,698 |
public String intern (char ch[], int start, int length) { int index = 0; int hash = 0; Object bucket []; // Generate a hash code. This is a widely used string hash, // often attributed to Brian Kernighan. for (int i = start; i < start + length; i++) hash = 31 * hash + ch [i]; hash = (hash & 0x7fffffff) % SY... | public String intern (char ch[], int start, int length) { int index = 0; int hash = 0; Object[] bucket; // Generate a hash code. This is a widely used string hash, // often attributed to Brian Kernighan. for (int i = start; i < start + length; i++) hash = 31 * hash + ch [i]; hash = (hash & 0x7fffffff) % SYM... | 12,699 |
public String intern (char ch[], int start, int length) { int index = 0; int hash = 0; Object bucket []; // Generate a hash code. This is a widely used string hash, // often attributed to Brian Kernighan. for (int i = start; i < start + length; i++) hash = 31 * hash + ch [i]; hash = (hash & 0x7fffffff) % SY... | public String intern (char ch[], int start, int length) { int index = 0; int hash = 0; Object bucket []; // Generate a hash code. This is a widely used string hash, // often attributed to Brian Kernighan. for (int i = start; i < start + length; i++) { hash = 31 * hash + ch[i]; } hash = (hash & 0x7fffffff) %... | 12,700 |
public String intern (char ch[], int start, int length) { int index = 0; int hash = 0; Object bucket []; // Generate a hash code. This is a widely used string hash, // often attributed to Brian Kernighan. for (int i = start; i < start + length; i++) hash = 31 * hash + ch [i]; hash = (hash & 0x7fffffff) % SY... | public String intern (char ch[], int start, int length) { int index = 0; int hash = 0; Object bucket []; // Generate a hash code. This is a widely used string hash, // often attributed to Brian Kernighan. for (int i = start; i < start + length; i++) hash = 31 * hash + ch [i]; hash = (hash & 0x7fffffff) % SY... | 12,701 |
private void parseAttDef (String elementName) throws Exception { String name; String type; String enumer = null; // Read the attribute name. name = readNmtoken (true); // Read the attribute type. requireWhitespace (); type = readAttType (); // Get the string of enumerated values if necessary. if (handler.get... | private void parseAttDef (String elementName) throws Exception { String name; String type; String enumer = null; // Read the attribute name. name = readNmtoken (true); // Read the attribute type. requireWhitespace (); type = readAttType (); // Get the string of enumerated values if necessary. if (handler.str... | 12,703 |
private void parseAttDef (String elementName) throws Exception { String name; String type; String enumer = null; // Read the attribute name. name = readNmtoken (true); // Read the attribute type. requireWhitespace (); type = readAttType (); // Get the string of enumerated values if necessary. if (handler.get... | private void parseAttDef (String elementName) throws Exception { String name; String type; String enumer = null; // Read the attribute name. name = readNmtoken (true); // Read the attribute type. requireWhitespace (); type = readAttType (); // Get the string of enumerated values if necessary. if (handler.get... | 12,704 |
private void parseAttDef (String elementName) throws Exception { String name; String type; String enumer = null; // Read the attribute name. name = readNmtoken (true); // Read the attribute type. requireWhitespace (); type = readAttType (); // Get the string of enumerated values if necessary. if (handler.get... | private void parseAttDef (String elementName) throws Exception { String name; String type; String enumer = null; // Read the attribute name. name = readNmtoken (true); // Read the attribute type. requireWhitespace (); type = readAttType (); // Get the string of enumerated values if necessary. if (handler.get... | 12,705 |
private void parseAttlistDecl () throws Exception { String elementName; requireWhitespace (); elementName = readNmtoken (true); boolean white = tryWhitespace (); while (!tryRead ('>')) { if (!white) error ("whitespace required before attribute definition"); parseAttDef (elementName); white = tryW... | private void parseAttlistDecl () throws Exception { String elementName; requireWhitespace (); elementName = readNmtoken (true); boolean white = tryWhitespace (); while (!tryRead ('>')) { if (!white) error ("whitespace required before attribute definition"); parseAttDef (elementName); white = tryW... | 12,706 |
private void parseAttribute (String name) throws Exception { String aname; String type; String value; int flags = LIT_ATTRIBUTE | LIT_ENTITY_REF; // Read the attribute name. aname = readNmtoken (true); type = getAttributeType (name, aname); // Parse '=' parseEq (); // Read the value, normalizing whitespace /... | private void parseAttribute (String name) throws Exception { String aname; String type; String value; int flags = LIT_ATTRIBUTE | LIT_ENTITY_REF; // Read the attribute name. aname = readNmtoken (true); type = getAttributeType (name, aname); // Parse '=' parseEq (); // Read the value, normalizing whitespace /... | 12,707 |
private void parseAttribute (String name) throws Exception { String aname; String type; String value; int flags = LIT_ATTRIBUTE | LIT_ENTITY_REF; // Read the attribute name. aname = readNmtoken (true); type = getAttributeType (name, aname); // Parse '=' parseEq (); // Read the value, normalizing whitespace /... | private void parseAttribute (String name) throws Exception { String aname; String type; String value; int flags = LIT_ATTRIBUTE | LIT_ENTITY_REF; // Read the attribute name. aname = readNmtoken (true); type = getAttributeType (name, aname); // Parse '=' parseEq (); // Read the value, normalizing whitespace /... | 12,708 |
private void parseCharData () throws Exception { char c; int state = 0; boolean pureWhite = false; // assert (dataBufferPos == 0); // are we expecting pure whitespace? it might be dirty... if ((currentElementContent == CONTENT_ELEMENTS) && !isDirtyCurrentElement) pureWhite = true; // always report right ... | private void parseCharData () throws Exception { char c; int state = 0; boolean pureWhite = false; // assert (dataBufferPos == 0); // are we expecting pure whitespace? it might be dirty... if ((currentElementContent == CONTENT_ELEMENTS) && !isDirtyCurrentElement) pureWhite = true; // always report right ... | 12,709 |
private void parseCharData () throws Exception { char c; int state = 0; boolean pureWhite = false; // assert (dataBufferPos == 0); // are we expecting pure whitespace? it might be dirty... if ((currentElementContent == CONTENT_ELEMENTS) && !isDirtyCurrentElement) pureWhite = true; // always report right ... | private void parseCharData () throws Exception { char c; int state = 0; boolean pureWhite = false; // assert (dataBufferPos == 0); // are we expecting pure whitespace? it might be dirty... if ((currentElementContent == CONTENT_ELEMENTS) && !isDirtyCurrentElement) pureWhite = true; // always report right ... | 12,710 |
private void parseCharData () throws Exception { char c; int state = 0; boolean pureWhite = false; // assert (dataBufferPos == 0); // are we expecting pure whitespace? it might be dirty... if ((currentElementContent == CONTENT_ELEMENTS) && !isDirtyCurrentElement) pureWhite = true; // always report right ... | private void parseCharData () throws Exception { char c; int state = 0; boolean pureWhite = false; // assert (dataBufferPos == 0); // are we expecting pure whitespace? it might be dirty... if ((currentElementContent == CONTENT_ELEMENTS) && !isDirtyCurrentElement) pureWhite = true; // always report right ... | 12,711 |
private void parseCharData () throws Exception { char c; int state = 0; boolean pureWhite = false; // assert (dataBufferPos == 0); // are we expecting pure whitespace? it might be dirty... if ((currentElementContent == CONTENT_ELEMENTS) && !isDirtyCurrentElement) pureWhite = true; // always report right ... | private void parseCharData () throws Exception { char c; int state = 0; boolean pureWhite = false; // assert (dataBufferPos == 0); // are we expecting pure whitespace? it might be dirty... if ((currentElementContent == CONTENT_ELEMENTS) && !isDirtyCurrentElement) pureWhite = true; // always report right ... | 12,712 |
private void parseConditionalSect (char saved []) throws Exception { skipWhitespace (); if (tryRead ("INCLUDE")) { skipWhitespace (); require ('['); // VC: Proper Conditional Section/PE Nesting if (readBuffer != saved) handler.verror ("Illegal Conditional Section/PE nesting"); skipWhitesp... | private void parseConditionalSect(char[] saved) throws Exception { skipWhitespace (); if (tryRead ("INCLUDE")) { skipWhitespace (); require ('['); // VC: Proper Conditional Section/PE Nesting if (readBuffer != saved) handler.verror ("Illegal Conditional Section/PE nesting"); skipWhitespac... | 12,713 |
private void parseConditionalSect (char saved []) throws Exception { skipWhitespace (); if (tryRead ("INCLUDE")) { skipWhitespace (); require ('['); // VC: Proper Conditional Section/PE Nesting if (readBuffer != saved) handler.verror ("Illegal Conditional Section/PE nesting"); skipWhitesp... | private void parseConditionalSect (char saved []) throws Exception { skipWhitespace (); if (tryRead ("INCLUDE")) { skipWhitespace (); require ('['); // VC: Proper Conditional Section/PE Nesting if (readBuffer != saved) handler.verror ("Illegal Conditional Section/PE nesting"); skipWhitesp... | 12,714 |
private void parseConditionalSect (char saved []) throws Exception { skipWhitespace (); if (tryRead ("INCLUDE")) { skipWhitespace (); require ('['); // VC: Proper Conditional Section/PE Nesting if (readBuffer != saved) handler.verror ("Illegal Conditional Section/PE nesting"); skipWhitesp... | private void parseConditionalSect (char saved []) throws Exception { skipWhitespace (); if (tryRead ("INCLUDE")) { skipWhitespace (); require ('['); // VC: Proper Conditional Section/PE Nesting if (readBuffer != saved) { handler.verror("Illegal Conditional Section/PE nesting"); } skipWhit... | 12,715 |
private void parseContentspec (String name) throws Exception {// FIXME: move elementDecl() into setElement(), pass EMTPY/ANY ... if (tryRead ("EMPTY")) { setElement (name, CONTENT_EMPTY, null, null); if (!skippedPE) handler.getDeclHandler ().elementDecl (name, "EMPTY"); return; } else if (tryRead... | private void parseContentspec (String name) throws Exception {// FIXME: move elementDecl() into setElement(), pass EMTPY/ANY ... if (tryRead ("EMPTY")) { setElement (name, CONTENT_EMPTY, null, null); if (!skippedPE) { handler.getDeclHandler().elementDecl(name, "EMPTY"); } return; } else if (tryRe... | 12,716 |
private void parseContentspec (String name) throws Exception {// FIXME: move elementDecl() into setElement(), pass EMTPY/ANY ... if (tryRead ("EMPTY")) { setElement (name, CONTENT_EMPTY, null, null); if (!skippedPE) handler.getDeclHandler ().elementDecl (name, "EMPTY"); return; } else if (tryRead... | private void parseContentspec (String name) throws Exception {// FIXME: move elementDecl() into setElement(), pass EMTPY/ANY ... if (tryRead ("EMPTY")) { setElement (name, CONTENT_EMPTY, null, null); if (!skippedPE) handler.getDeclHandler ().elementDecl (name, "EMPTY"); return; } else if (tryRead... | 12,717 |
private void parseContentspec (String name) throws Exception {// FIXME: move elementDecl() into setElement(), pass EMTPY/ANY ... if (tryRead ("EMPTY")) { setElement (name, CONTENT_EMPTY, null, null); if (!skippedPE) handler.getDeclHandler ().elementDecl (name, "EMPTY"); return; } else if (tryRead... | private void parseContentspec (String name) throws Exception {// FIXME: move elementDecl() into setElement(), pass EMTPY/ANY ... if (tryRead ("EMPTY")) { setElement (name, CONTENT_EMPTY, null, null); if (!skippedPE) handler.getDeclHandler ().elementDecl (name, "EMPTY"); return; } else if (tryRead... | 12,718 |
private void parseContentspec (String name) throws Exception {// FIXME: move elementDecl() into setElement(), pass EMTPY/ANY ... if (tryRead ("EMPTY")) { setElement (name, CONTENT_EMPTY, null, null); if (!skippedPE) handler.getDeclHandler ().elementDecl (name, "EMPTY"); return; } else if (tryRead... | private void parseContentspec (String name) throws Exception {// FIXME: move elementDecl() into setElement(), pass EMTPY/ANY ... if (tryRead ("EMPTY")) { setElement (name, CONTENT_EMPTY, null, null); if (!skippedPE) handler.getDeclHandler ().elementDecl (name, "EMPTY"); return; } else if (tryRead... | 12,719 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.