bugged
stringlengths
6
599k
fixed
stringlengths
10
599k
__index_level_0__
int64
0
1.13M
private boolean isBefore(int calYear, int calMonth, int calDayOfMonth, int calDayOfWeek, int calMillis, int mode, int month, int day, int dayOfWeek, int millis) { // This method is called by Calendar, so we mustn't use that class. // We have to do all calculations by hand. // check the months...
private boolean isBefore(int calYear, int calMonth, int calDayOfMonth, int calDayOfWeek, int calMillis, int mode, int month, int day, int dayOfWeek, int millis) { // This method is called by Calendar, so we mustn't use that class. // We have to do all calculations by hand. // check the months...
11,820
private void readObject(java.io.ObjectInputStream input) throws java.io.IOException, ClassNotFoundException { input.defaultReadObject(); if (serialVersionOnStream == 0) { // initialize the new fields to default values. dstSavings = 60 * 60 * 1000; endMode = DOW_IN_MONTH_MODE; startMode = DOW_IN_MONTH_M...
private void readObject(java.io.ObjectInputStream input) throws java.io.IOException, ClassNotFoundException { input.defaultReadObject(); if (serialVersionOnStream == 0) { // initialize the new fields to default values. dstSavings = 60 * 60 * 1000; endMode = DOW_IN_MONTH_MODE; startMode = DOW_IN_MONTH_M...
11,821
public void setEndRule(int month, int day, int dayOfWeek, int time) { this.endMode = checkRule(month, day, dayOfWeek); this.endMonth = month; // FIXME: XXX: JDK 1.2 allows negative values and has 2 new variations // of this method. this.endDay = Math.abs(day); this.endDayOfWeek = Math.abs(dayOfWeek...
public void setEndRule(int month, int day, int dayOfWeek, int time) { this.endMode = checkRule(month, day, dayOfWeek); this.endMonth = month; // FIXME: XXX: JDK 1.2 allows negative values and has 2 new variations // of this method. this.endDay = day; this.endDayOfWeek = Math.abs(dayOfWeek); this...
11,822
public void setStartRule(int month, int day, int dayOfWeek, int time) { this.startMode = checkRule(month, day, dayOfWeek); this.startMonth = month; // FIXME: XXX: JDK 1.2 allows negative values and has 2 new variations // of this method. this.startDay = Math.abs(day); this.startDayOfWeek = Math.abs...
public void setStartRule(int month, int day, int dayOfWeek, int time) { this.startMode = checkRule(month, day, dayOfWeek); this.startMonth = month; // FIXME: XXX: JDK 1.2 allows negative values and has 2 new variations // of this method. this.startDay = day; this.startDayOfWeek = Math.abs(dayOfWeek...
11,824
public void setStartRule(int month, int day, int dayOfWeek, int time) { this.startMode = checkRule(month, day, dayOfWeek); this.startMonth = month; // FIXME: XXX: JDK 1.2 allows negative values and has 2 new variations // of this method. this.startDay = Math.abs(day); this.startDayOfWeek = Math.abs...
public void setStartRule(int month, int day, int dayOfWeek, int time) { this.startMode = checkRule(month, day, dayOfWeek); this.startMonth = month; // FIXME: XXX: JDK 1.2 allows negative values and has 2 new variations // of this method. this.startDay = Math.abs(day); this.startDayOfWeek = Math.abs...
11,825
public String toString() { // the test for useDaylight is an incompatibility to jdk1.2, but // I think this shouldn't hurt. return getClass().getName() + "[" + "id=" + getID() + ",offset=" + rawOffset + ",dstSavings=" + dstSavings + ",useDaylight=" + useDaylight + (useDaylight ? ",...
public String toString() { // the test for useDaylight is an incompatibility to jdk1.2, but // I think this shouldn't hurt. return getClass().getName() + "[" + "id=" + getID() + ",offset=" + rawOffset + ",dstSavings=" + dstSavings + ",useDaylight=" + useDaylight + (useDaylight ? ",...
11,826
public long write(ByteBuffer[] srcs) throws IOException;
long write(ByteBuffer[] srcs, int offset, int length) throws IOException;
11,827
public long read(ByteBuffer[] srcs) throws IOException;
long read(ByteBuffer[] srcs, int offset, int length) throws IOException;
11,828
getMaxExpansion(int value){ //************ Implement me!!!!!!!!! return(5);}
getMaxExpansion(int value){ //************ Implement me!!!!!!!!! return(5);}
11,829
getOffset(){ return(pos);}
getOffset(){ return(pos);}
11,830
previous(){ --pos; if (pos < 0) return(NULLORDER); String s = str.charAt(pos) + ""; return(rbc.getCollationElementValue(s));}
previous(){ --pos; if (pos < 0) return(NULLORDER); String s = str.charAt(pos) + ""; return(rbc.getCollationElementValue(s));}
11,831
previous(){ --pos; if (pos < 0) return(NULLORDER); String s = str.charAt(pos) + ""; return(rbc.getCollationElementValue(s));}
previous(){ --pos; if (pos < 0) return(NULLORDER); String s = str.charAt(pos) + ""; return(rbc.getCollationElementValue(s));}
11,832
setOffset(int offset){ if (offset < 0) throw new IllegalArgumentException("Negative offset: " + offset); if ((str.length() > 0) && (offset > 0)) throw new IllegalArgumentException("Offset too large: " + offset); else if (offset > (str.length() - 1)) throw new IllegalArgumentException("Offset too large: " + ...
setOffset(int offset){ if (offset < 0) throw new IllegalArgumentException("Negative offset: " + offset); if ((str.length() > 0) && (offset > 0)) throw new IllegalArgumentException("Offset too large: " + offset); else if (offset > (str.length() - 1)) throw new IllegalArgumentException("Offset too large: " + ...
11,833
setOffset(int offset){ if (offset < 0) throw new IllegalArgumentException("Negative offset: " + offset); if ((str.length() > 0) && (offset > 0)) throw new IllegalArgumentException("Offset too large: " + offset); else if (offset > (str.length() - 1)) throw new IllegalArgumentException("Offset too large: " + ...
setOffset(int offset){ if (offset < 0) throw new IllegalArgumentException("Negative offset: " + offset); if ((str.length() > 0) && (offset > 0)) throw new IllegalArgumentException("Offset too large: " + offset); else if (offset > (str.length() - 1)) throw new IllegalArgumentException("Offset too large: " + ...
11,834
setOffset(int offset){ if (offset < 0) throw new IllegalArgumentException("Negative offset: " + offset); if ((str.length() > 0) && (offset > 0)) throw new IllegalArgumentException("Offset too large: " + offset); else if (offset > (str.length() - 1)) throw new IllegalArgumentException("Offset too large: " + ...
setOffset(int offset){ if (offset < 0) throw new IllegalArgumentException("Negative offset: " + offset); if ((str.length() > 0) && (offset > 0)) throw new IllegalArgumentException("Offset too large: " + offset); else if (offset > (str.length() - 1)) throw new IllegalArgumentException("Offset too large: " + ...
11,835
setText(String str){ this.str = str; pos = 0;}
setText(String str){ this.str = str; pos = 0;}
11,836
public static String[] read(InputStream input) { WStringSeqHolder h = new WStringSeqHolder(); h._read(input); return h.value; }
public static String[] read(InputStream input) { WStringSeqHolder h = new WStringSeqHolder(); h._read(input); return h.value; }
11,837
public static void write(OutputStream output, String[] value) { WStringSeqHolder h = new WStringSeqHolder(value); h._write(output); }
public static void write(OutputStream output, String[] value) { WStringSeqHolder h = new WStringSeqHolder(value); h._write(output); }
11,838
public WStringSeqHolder(String[] initial_value) { value = initial_value; typecode.setLength(value.length); }
public WStringSeqHolder() { value = initial_value; typecode.setLength(value.length); }
11,839
public WStringSeqHolder(String[] initial_value) { value = initial_value; typecode.setLength(value.length); }
public WStringSeqHolder(String[] initial_value) { value = initial_value; typecode.setLength(value.length); }
11,840
public BigDecimal (BigInteger num, int scale) throws NumberFormatException { if (scale < 0) throw new NumberFormatException ("scale of " + scale + " is < 0"); this.intVal = num; this.scale = scale; }
public BigDecimal (BigInteger num) { if (scale < 0) throw new NumberFormatException ("scale of " + scale + " is < 0"); this.intVal = num; this.scale = scale; }
11,841
public BigDecimal (BigInteger num, int scale) throws NumberFormatException { if (scale < 0) throw new NumberFormatException ("scale of " + scale + " is < 0"); this.intVal = num; this.scale = scale; }
public BigDecimal (BigInteger num, int scale) throws NumberFormatException { if (scale < 0) throw new NumberFormatException ("scale of " + scale + " is < 0"); this.intVal = num; this.scale = scale; }
11,842
protected void paintString(Graphics g, int x, int y, int width, int height, int amountFull, Insets b) { String str = progressBar.getString(); int full = getAmountFull(b, width, height); Point placement = getStringPlacement(g, progressBar.getString(), ...
protected void paintString(Graphics g, int x, int y, int width, int height, int amountFull, Insets b) { String str = progressBar.getString(); int full = getAmountFull(b, width, height); Point placement = getStringPlacement(g, progressBar.getString(), ...
11,843
public Font deriveFont (AffineTransform a){ if (a == null) throw new IllegalArgumentException ("Affine transformation is null"); return peer.deriveFont (this, a);}
public Font deriveFont (int style, float size){ if (a == null) throw new IllegalArgumentException ("Affine transformation is null"); return peer.deriveFont (this, a);}
11,844
public Font deriveFont (AffineTransform a){ if (a == null) throw new IllegalArgumentException ("Affine transformation is null"); return peer.deriveFont (this, a);}
public Font deriveFont (AffineTransform a){ if (a == null) throw new IllegalArgumentException ("Affine transformation is null"); return peer.deriveFont (this, a);}
11,845
public final SelectableChannel configureBlocking (boolean block) throws IOException { synchronized (LOCK) { blocking = true; implConfigureBlocking (block); } return this; }
public final SelectableChannel configureBlocking(boolean blocking) throws IOException { synchronized (LOCK) { blocking = true; implConfigureBlocking (block); } return this; }
11,846
public final SelectableChannel configureBlocking (boolean block) throws IOException { synchronized (LOCK) { blocking = true; implConfigureBlocking (block); } return this; }
public final SelectableChannel configureBlocking (boolean block) throws IOException { synchronized (blockingLock()) { blocking = true; implConfigureBlocking (block); } return this; }
11,847
public final SelectableChannel configureBlocking (boolean block) throws IOException { synchronized (LOCK) { blocking = true; implConfigureBlocking (block); } return this; }
public final SelectableChannel configureBlocking (boolean block) throws IOException { synchronized (LOCK) { blocking = true; implConfigureBlocking (block); } return this; }
11,848
protected abstract void implConfigureBlocking (boolean block) throws IOException;
protected abstract void implConfigureBlocking(boolean blocking) throws IOException;
11,849
public final boolean isRegistered() { return registered > 0; }
public final boolean isRegistered() { return ! keys.isEmpty(); }
11,850
public final SelectionKey keyFor(Selector selector) { try { return register (selector, 0, null); } catch (Exception e) { return null; } }
public final SelectionKey keyFor(Selector selector) { try { synchronized (blockingLock()) { return locate(selector); } } catch (Exception e) { return null; } }
11,851
private SelectionKey locate (Selector selector) { if (keys == null) return null; SelectionKey k = null; ListIterator it = keys.listIterator (); while (it.hasNext ()) { k = (SelectionKey) it.next (); if (k.selector () == selector) { return k; } }...
private SelectionKey locate (Selector selector) { if (keys == null) return null; SelectionKey k = null; ListIterator it = keys.listIterator (); while (it.hasNext ()) { k = (SelectionKey) it.next (); if (k.selector () == selector) { return k; } }...
11,852
private SelectionKey locate (Selector selector) { if (keys == null) return null; SelectionKey k = null; ListIterator it = keys.listIterator (); while (it.hasNext ()) { k = (SelectionKey) it.next (); if (k.selector () == selector) { return k; } }...
private SelectionKey locate (Selector selector) { if (keys == null) return null; SelectionKey k = null; ListIterator it = keys.listIterator (); while (it.hasNext ()) { k = (SelectionKey) it.next (); if (k.selector () == selector) { return k; } }...
11,853
private SelectionKey locate (Selector selector) { if (keys == null) return null; SelectionKey k = null; ListIterator it = keys.listIterator (); while (it.hasNext ()) { k = (SelectionKey) it.next (); if (k.selector () == selector) { return k; } }...
private SelectionKey locate (Selector selector) { if (keys == null) return null; SelectionKey k = null; ListIterator it = keys.listIterator (); while (it.hasNext ()) { k = (SelectionKey) it.next (); if (k.selector () == selector) { return k; } }...
11,854
private SelectionKey locate (Selector selector) { if (keys == null) return null; SelectionKey k = null; ListIterator it = keys.listIterator (); while (it.hasNext ()) { k = (SelectionKey) it.next (); if (k.selector () == selector) { return k; } }...
private SelectionKey locate (Selector selector) { if (keys == null) return null; SelectionKey k = null; ListIterator it = keys.listIterator (); while (it.hasNext ()) { k = (SelectionKey) it.next (); if (k.selector () == selector) { return null; } ...
11,855
public final SelectionKey register (Selector selin, int ops, Object att) throws ClosedChannelException { if (!isOpen ()) throw new ClosedChannelException(); SelectionKey k = null; AbstractSelector selector = (AbstractSelector) selin; synchronized (LOCK) { k = locate (selector); ...
public final SelectionKey register (Selector selin, int ops, Object att) throws ClosedChannelException { if (!isOpen ()) throw new ClosedChannelException(); if ((ops & ~validOps()) != 0) throw new IllegalArgumentException(); SelectionKey key = null; AbstractSelector selector = (AbstractSelector) se...
11,856
public final SelectionKey register (Selector selin, int ops, Object att) throws ClosedChannelException { if (!isOpen ()) throw new ClosedChannelException(); SelectionKey k = null; AbstractSelector selector = (AbstractSelector) selin; synchronized (LOCK) { k = locate (selector); ...
public final SelectionKey register (Selector selin, int ops, Object att) throws ClosedChannelException { if (!isOpen ()) throw new ClosedChannelException(); SelectionKey k = null; AbstractSelector selector = (AbstractSelector) selin; synchronized (blockingLock()) { k = locate (selecto...
11,857
public final SelectionKey register (Selector selin, int ops, Object att) throws ClosedChannelException { if (!isOpen ()) throw new ClosedChannelException(); SelectionKey k = null; AbstractSelector selector = (AbstractSelector) selin; synchronized (LOCK) { k = locate (selector); ...
public final SelectionKey register (Selector selin, int ops, Object att) throws ClosedChannelException { if (!isOpen ()) throw new ClosedChannelException(); SelectionKey k = null; AbstractSelector selector = (AbstractSelector) selin; synchronized (LOCK) { key = locate(selector); ...
11,858
public final SelectionKey register (Selector selin, int ops, Object att) throws ClosedChannelException { if (!isOpen ()) throw new ClosedChannelException(); SelectionKey k = null; AbstractSelector selector = (AbstractSelector) selin; synchronized (LOCK) { k = locate (selector); ...
public final SelectionKey register (Selector selin, int ops, Object att) throws ClosedChannelException { if (!isOpen ()) throw new ClosedChannelException(); SelectionKey k = null; AbstractSelector selector = (AbstractSelector) selin; synchronized (LOCK) { k = locate (selector); ...
11,859
public final SelectionKey register (Selector selin, int ops, Object att) throws ClosedChannelException { if (!isOpen ()) throw new ClosedChannelException(); SelectionKey k = null; AbstractSelector selector = (AbstractSelector) selin; synchronized (LOCK) { k = locate (selector); ...
public final SelectionKey register (Selector selin, int ops, Object att) throws ClosedChannelException { if (!isOpen ()) throw new ClosedChannelException(); SelectionKey k = null; AbstractSelector selector = (AbstractSelector) selin; synchronized (LOCK) { k = locate (selector); ...
11,860
public final SelectionKey register (Selector selin, int ops, Object att) throws ClosedChannelException { if (!isOpen ()) throw new ClosedChannelException(); SelectionKey k = null; AbstractSelector selector = (AbstractSelector) selin; synchronized (LOCK) { k = locate (selector); ...
public final SelectionKey register (Selector selin, int ops, Object att) throws ClosedChannelException { if (!isOpen ()) throw new ClosedChannelException(); SelectionKey k = null; AbstractSelector selector = (AbstractSelector) selin; synchronized (LOCK) { k = locate (selector); ...
11,861
public final SelectionKey register (Selector selin, int ops, Object att) throws ClosedChannelException { if (!isOpen ()) throw new ClosedChannelException(); SelectionKey k = null; AbstractSelector selector = (AbstractSelector) selin; synchronized (LOCK) { k = locate (selector); ...
public final SelectionKey register (Selector selin, int ops, Object att) throws ClosedChannelException { if (!isOpen ()) throw new ClosedChannelException(); SelectionKey k = null; AbstractSelector selector = (AbstractSelector) selin; synchronized (LOCK) { k = locate (selector); ...
11,862
public final SelectionKey register (Selector selin, int ops, Object att) throws ClosedChannelException { if (!isOpen ()) throw new ClosedChannelException(); SelectionKey k = null; AbstractSelector selector = (AbstractSelector) selin; synchronized (LOCK) { k = locate (selector); ...
public final SelectionKey register (Selector selin, int ops, Object att) throws ClosedChannelException { if (!isOpen ()) throw new ClosedChannelException(); SelectionKey k = null; AbstractSelector selector = (AbstractSelector) selin; synchronized (LOCK) { k = locate (selector); ...
11,863
public boolean equals(Object o) { if (! (o instanceof GregorianCalendar)) return false; GregorianCalendar cal = (GregorianCalendar) o; return (cal.getTimeInMillis() == getTimeInMillis()); }
public boolean equals(Object o) { if (! (o instanceof GregorianCalendar)) return false; GregorianCalendar cal = (GregorianCalendar) o; return (cal.gregorianCutover == gregorianCutover && super.equals(o)); }
11,864
public MetalButtonUI() { super(); focusColor = getFocusColor(); selectColor = getSelectColor(); disabledTextColor = getDisabledTextColor(); }
public MetalButtonUI() { super(); focusColor = getFocusColor(); selectColor = getSelectColor(); disabledTextColor = getDisabledTextColor(); }
11,865
public static ComponentUI createUI(JComponent component) { if (instance == null) instance = new MetalButtonUI(); return instance; }
public static ComponentUI createUI(JComponent component) { if (instance == null) instance = new MetalButtonUI(); return instance; }
11,866
public void installDefaults(AbstractButton button) { super.installDefaults(button); UIDefaults defaults = UIManager.getLookAndFeelDefaults(); button.setFont(defaults.getFont("Button.font")); if (button.getParent() instanceof JToolBar) button.setBorder(MetalBorders.getToolbarButtonBorder()); }
public void installDefaults(AbstractButton button) { super.installDefaults(button); UIDefaults defaults = UIManager.getLookAndFeelDefaults(); button.setFont(defaults.getFont("Button.font")); if (button.getParent() instanceof JToolBar) button.setBorder(MetalBorders.getToolbarButtonBorder()); }
11,867
protected void installDefaults() { UIDefaults defaults = UIManager.getLookAndFeelDefaults(); menuBar.setBackground(defaults.getColor("MenuBar.background")); menuBar.setBorder(defaults.getBorder("MenuBar.border")); menuBar.setFont(defaults.getFont("MenuBar.font")); menuBar.setForeground(defaults.getCol...
protected void installDefaults() { UIDefaults defaults = UIManager.getLookAndFeelDefaults(); menuBar.setBackground(defaults.getColor("MenuBar.background")); menuBar.setBorder(defaults.getBorder("MenuBar.border")); menuBar.setFont(defaults.getFont("MenuBar.font")); menuBar.setForeground(defaults.getCol...
11,868
public static void main(String[] args) throws SyntaxErrorException { ParsedArguments cmdLine = HELP_INFO.parse(args); DeviceManager dm; try { dm = InitialNaming.lookup(DeviceManager.NAME); boolean isAction = PARAM_ACTION.isSet(cmdLine); boolean isInitMBR = PARAM_INITMBR.isSet(cmdLine); boolean isDevice = PA...
public static void main(String[] args) throws SyntaxErrorException { ParsedArguments cmdLine = HELP_INFO.parse(args); DeviceManager dm; try { dm = InitialNaming.lookup(DeviceManager.NAME); boolean isAction = PARAM_ACTION.isSet(cmdLine); boolean isInitMBR = PARAM_INITMBR.isSet(cmdLine); boolean isDevice = PA...
11,869
private static void modifyPartition(String description, BlockDeviceAPI api, BootSector bs) throws IOException { // arg 1 should be in the form id:start:size:fs StringTokenizer st = new StringTokenizer(description, ":"); int id = Integer.parseInt(st.nextToken()); //BUG in long //long start = Long.parseLong(st.next...
private static void modifyPartition(String description, BlockDeviceAPI api, BootSector bs, Device dev) throws IOException { // arg 1 should be in the form id:start:size:fs StringTokenizer st = new StringTokenizer(description, ":"); int id = Integer.parseInt(st.nextToken()); //BUG in long //long start = Long.parse...
11,870
postEvent(Event event) { boolean retVal = false; MenuContainer parent = getParent(); if (parent == null) { if (this instanceof MenuBar) { MenuBar menuBar = (MenuBar) this; if (menuBar.frame != null) retVal = menuBar.frame.postEvent(event); } ...
postEvent(Event event) { boolean retVal = false; MenuContainer parent = getParent(); if (parent == null) { if (this instanceof MenuBar) { MenuBar menuBar = (MenuBar) this; if (menuBar.frame != null) retVal = menuBar.frame.postEvent(event); } ...
11,873
public float getLSB () throws NotImplementedException { throw new Error ("not implemented"); }
public float getLSB () throws NotImplementedException { throw new Error ("not implemented"); }
11,874
public float getLSB () throws NotImplementedException { throw new Error ("not implemented"); }
public float getLSB () throws NotImplementedException { if (horizontal) return (float) bounds.getX(); return (float) bounds.getY(); }
11,875
public float getRSB () throws NotImplementedException { throw new Error ("not implemented"); }
public float getRSB () throws NotImplementedException { throw new Error ("not implemented"); }
11,876
public float getRSB () throws NotImplementedException { throw new Error ("not implemented"); }
public float getRSB () throws NotImplementedException { if (horizontal) return (float) (advanceX - (bounds.getX() + bounds.getWidth())); return (float) (advanceY - (bounds.getY() + bounds.getHeight())); }
11,877
public boolean implies(Permission perm) { for (Iterator i = list.iterator(); i.hasNext(); ) { final Permission p = (Permission)i.next(); if (p.implies(perm)) { return true; } } return false; }
public boolean implies(Permission perm) { for (Iterator i = list.iterator(); i.hasNext(); ) { final Permission p = (Permission)i.next(); if (p.implies(perm)) { return true; } } return false; }
11,878
public ServerSocketChannel(SelectorProvider provider) { super(provider); }
protected ServerSocketChannel(SelectorProvider provider) { super(provider); }
11,879
public void actionPerformed(ActionEvent ev) { caret.setVisible(!caret.isVisible()); }
public void actionPerformed(ActionEvent ev) { Caret c = caret; if (c != null) c.setVisible(!c.isVisible()); }
11,881
public void update() { stop(); setDelay(caret.getBlinkRate()); if (editable) start(); else caret.setVisible(false); }
public void update() { stop(); Caret c = caret; if (c != null) { setDelay(c.getBlinkRate()); if (editable) start(); else caret.setVisible(false); }
11,882
public void update() { stop(); setDelay(caret.getBlinkRate()); if (editable) start(); else caret.setVisible(false); }
public void update() { stop(); setDelay(caret.getBlinkRate()); if (editable) start(); else c.setVisible(false); } }
11,883
public Object getObject() throws IOException, ClassNotFoundException { ByteArrayInputStream istream = new ByteArrayInputStream(content); return new ObjectInputStream(istream).readObject(); }
public Object getObject() throws IOException, ClassNotFoundException { ByteArrayInputStream bais = new ByteArrayInputStream(content); ObjectInput oi = new ObjectInputStream(bais); Object obj = oi.readObject(); oi.close(); bais.close(); return new ObjectInputStream(istream).readObject(); }
11,885
public Object getObject() throws IOException, ClassNotFoundException { ByteArrayInputStream istream = new ByteArrayInputStream(content); return new ObjectInputStream(istream).readObject(); }
public Object getObject() throws IOException, ClassNotFoundException { ByteArrayInputStream istream = new ByteArrayInputStream(content); return obj; }
11,886
public byte[] getSignature() { return signature; }
public byte[] getSignature() { return (byte[]) signature.clone(); }
11,887
private Provider () { extendedLoaded = false; canonicalNames = new HashMap (); charsets = new HashMap (); // US-ASCII aka ISO646-US addCharset (new US_ASCII ()); // ISO-8859-1 aka ISO-LATIN-1 addCharset (new ISO_8859_1 ()); // UTF-8 addCharset (new UTF_8 ()); // UTF-16BE addCharset (...
Provider () { extendedLoaded = false; canonicalNames = new HashMap (); charsets = new HashMap (); // US-ASCII aka ISO646-US addCharset (new US_ASCII ()); // ISO-8859-1 aka ISO-LATIN-1 addCharset (new ISO_8859_1 ()); // UTF-8 addCharset (new UTF_8 ()); // UTF-16BE addCharset (new UTF_...
11,888
public Charset charsetForName (String charsetName) { Charset cs = (Charset) charsets.get(canonicalNames.get(charsetName.toLowerCase())); if(cs == null && !extendedLoaded) { loadExtended(); cs = (Charset) charsets.get(canonicalNames.get(charsetName.toLowerCase())); } return cs; }
public Charset charsetForName (String charsetName) { Charset cs = (Charset) charsets.get(canonicalNames.get(charsetName.toLowerCase())); if (cs == null) { loadExtended(); cs = (Charset) charsets.get(canonicalNames.get(charsetName.toLowerCase())); } return cs; }
11,889
private void loadExtended () { if(extendedLoaded) return; addCharset (new ISO_8859_3 ()); // ISO-8859-3 aka ISO-LATIN-3 addCharset (new ISO_8859_6 ()); // ISO-8859-6 (Arabic) addCharset (new ISO_8859_8 ()); // ISO-8859-8 (Hebrew) // Some more codepages addCharset (new Cp855()); // IBM...
private synchronized void loadExtended () { if(extendedLoaded) return; addCharset (new ISO_8859_3 ()); // ISO-8859-3 aka ISO-LATIN-3 addCharset (new ISO_8859_6 ()); // ISO-8859-6 (Arabic) addCharset (new ISO_8859_8 ()); // ISO-8859-8 (Hebrew) // Some more codepages addCharset (new Cp8...
11,890
public Windows1250() { super("Windows-1250", new String[] { "Windows1250", "ibm-5346_P100-1998", "ibm-5346", "cp1250", "cp-1250", "cp_1250", "windows1250", "windows_1250" }); lookupTable = lookup; }
public Windows1250() { super("windows-1250", new String[] { "Windows1250", "ibm-5346_P100-1998", "ibm-5346", "cp1250", "cp-1250", "cp_1250", "windows1250", "windows_1250" }); lookupTable = lookup; }
11,892
public Windows1252() { super("Windows-1252", new String[] { "Windows1252", "ibm-5348_P100-1997", "ibm-5348", "windows-1252", "cp1252", "cp-1252" }); lookupTable = lookup; }
public Windows1252() { super("windows-1252", new String[] { "Windows1252", "ibm-5348_P100-1997", "ibm-5348", "windows-1252", "cp1252", "cp-1252" }); lookupTable = lookup; }
11,893
public Windows1253() { super("Windows-1253", new String[] { "Windows1253", "cp1253", "cp-1253", "cp_1253", "windows1253", "windows_1253" }); lookupTable = lookup; }
public Windows1253() { super("windows-1253", new String[] { "Windows1253", "cp1253", "cp-1253", "cp_1253", "windows1253", "windows_1253" }); lookupTable = lookup; }
11,894
public Windows1254() { super("Windows-1254", new String[] { "Windows1254", "cp1254", "cp-1254", "cp_1254", "windows1254", "windows_1254" }); lookupTable = lookup; }
public Windows1254() { super("windows-1254", new String[] { "Windows1254", "cp1254", "cp-1254", "cp_1254", "windows1254", "windows_1254" }); lookupTable = lookup; }
11,895
public Windows1257() { super("Windows-1257", new String[] { "Windows1257", "cp1257", "cp-1257", "cp_1257", "windows1257", "windows_1257" }); lookupTable = lookup; }
public Windows1257() { super("windows-1257", new String[] { "Windows1257", "cp1257", "cp-1257", "cp_1257", "windows1257", "windows_1257" }); lookupTable = lookup; }
11,896
public Windows1255() { super("Windows-1255", new String[] { "Windows1255", "cp1255", "cp-1255", "cp_1255", "windows1255", "windows_1255" }); lookupTable = lookup; }
public Windows1255() { super("windows-1255", new String[] { "Windows1255", "cp1255", "cp-1255", "cp_1255", "windows1255", "windows_1255" }); lookupTable = lookup; }
11,897
public Windows1256() { super("Windows-1256", new String[] { "Windows1256", "cp1256", "cp-1256", "cp_1256", "windows1256", "windows_1256" }); lookupTable = lookup; }
public Windows1256() { super("windows-1256", new String[] { "Windows1256", "cp1256", "cp-1256", "cp_1256", "windows1256", "windows_1256" }); lookupTable = lookup; }
11,898
public Windows1258() { super("Windows-1258", new String[] { "Windows1258", "cp1258", "cp-1258", "cp_1258", "windows1258", "windows_1258" }); lookupTable = lookup; }
public Windows1258() { super("windows-1258", new String[] { "Windows1258", "cp1258", "cp-1258", "cp_1258", "windows1258", "windows_1258" }); lookupTable = lookup; }
11,899
public INode(Ext2FileSystem fs, byte[] data) { this.fs = fs; this.data = new byte[INODE_LENGTH]; System.arraycopy(data, 0, this.data, 0, INODE_LENGTH); }
public INode(Ext2FileSystem fs, INodeDescriptor desc, byte[] data) { this.fs = fs; this.data = new byte[INODE_LENGTH]; System.arraycopy(data, 0, this.data, 0, INODE_LENGTH); }
11,900
public byte[] getDataBlock(long i) throws IOException { //get the direct blocks (0; 11) if(i<12) return fs.getBlock( Ext2Utils.get32(data,40+(int)i*4) ); //see the indirect blocks (12; indirectCount-1) int indirectCount = fs.getSuperblock().getBlockSize() >> 2; //a block index is 4 bytes long if(i<12+indirectCo...
public byte[] getDataBlock(long i) throws IOException { //get the direct blocks (0; 11) if(i<12) return fs.getBlock( Ext2Utils.get32(data,40+(int)i*4) ); //see the indirect blocks (12; indirectCount-1) int indirectCount = fs.getSuperblock().getBlockSize() >> 2; //a block index is 4 bytes long if(i<12+indirectCo...
11,902
public int getMode() { int iMode=Ext2Utils.get16(data, 0); log.debug("INode.getIMode(): "+NumberUtils.hex(iMode)); return iMode; }
public int getMode() { int iMode=Ext2Utils.get16(data, 0); return iMode; }
11,903
public static void set32(byte[] data, int offset, int value) { data[offset] = (byte)(value & 0xFF); data[offset+1] = (byte)((value >> 8) & 0xFF); data[offset+2] = (byte)((value >> 16) & 0xFF); data[offset+3] = (byte)((value >> 32) & 0xFF); }
public static void set32(byte[] data, int offset, long value) { data[offset] = (byte)(value & 0xFF); data[offset+1] = (byte)((value >> 8) & 0xFF); data[offset+2] = (byte)((value >> 16) & 0xFF); data[offset+3] = (byte)((value >> 32) & 0xFF); }
11,904
public boolean isDescendant(TreePath path) { if (path == null) return false; int count = getPathCount(); if (path.getPathCount() < count) return false; for (int i = 0; i < count; i++) { if (!this.path[i].equals(path.getPathComponent(i))) return false; } return true; }
public boolean isDescendant(TreePath path) { if (path == null) return false; int count = getPathCount(); int otherPathLength = path.getPathCount(); if (otherPathLength < count) return false; for (int i = 0; i < count; i++) { if (!this.path[i].equals(path.getPathComponent(i))) return...
11,905
public boolean isDescendant(TreePath path) { if (path == null) return false; int count = getPathCount(); if (path.getPathCount() < count) return false; for (int i = 0; i < count; i++) { if (!this.path[i].equals(path.getPathComponent(i))) return false; } return true; }
public boolean isDescendant(TreePath path) { if (path == null) return false; int count = getPathCount(); if (path.getPathCount() < count) return false; while (otherPathLength > count) { if (!this.path[i].equals(path.getPathComponent(i))) return false; } return true; }
11,906
public boolean isDescendant(TreePath path) { if (path == null) return false; int count = getPathCount(); if (path.getPathCount() < count) return false; for (int i = 0; i < count; i++) { if (!this.path[i].equals(path.getPathComponent(i))) return false; } return true; }
public boolean isDescendant(TreePath path) { if (path == null) return false; int count = getPathCount(); if (path.getPathCount() < count) return false; for (int i = 0; i < count; i++) { if (!this.path[i].equals(path.getPathComponent(i))) return false; } return true; }
11,907
public boolean isDescendant(TreePath path) { if (path == null) return false; int count = getPathCount(); if (path.getPathCount() < count) return false; for (int i = 0; i < count; i++) { if (!this.path[i].equals(path.getPathComponent(i))) return false; } return true; }
public boolean isDescendant(TreePath path) { if (path == null) return false; int count = getPathCount(); if (path.getPathCount() < count) return false; for (int i = 0; i < count; i++) { if (!this.path[i].equals(path.getPathComponent(i))) return false; } return equals(path); }
11,908
public Image getVolatileOffscreenBuffer(Component comp, int proposedWidth, int proposedHeight) { int maxWidth = doubleBufferMaximumSize.width; int maxHeight = doubleBufferMaximumSize.height; return comp.createVolatileImage(Math.min(maxWidth, proposedWidth), ...
public Image getVolatileOffscreenBuffer(Component comp, int proposedWidth, int proposedHeight) { int maxWidth = doubleBufferMaximumSize.width; int maxHeight = doubleBufferMaximumSize.height; return comp.createVolatileImage(Math.min(maxWidth, proposedWidth), ...
11,909
public Object createValue(UIDefaults table) { throw new Error("not implemented"); }
public Object createValue(UIDefaults table) { InputMap im = new InputMap (); for (int i = 0; 2*i+1 < bind.length; ++i) { im.put (KeyStroke.getKeyStroke ((String) bind[2*i]), bind[2*i+1]); } return im; }
11,911
public ProxyLazyValue(String s) { throw new Error("not implemented"); }
public ProxyLazyValue(String s) { final String className = s; inner = new LazyValue () { public Object createValue (UIDefaults table) { try { return Class .forName (className) .getConstructor (new Class[] {}) .newInstance (new Object[] {}); } catch (Exception e) { return null; } } }; }
11,912
public Object createValue(UIDefaults table) { throw new Error("not implemented"); }
public Object createValue(UIDefaults table) { return inner.createValue (table); }
11,913
public void addPropertyChangeListener(PropertyChangeListener l) { throw new Error("not implemented"); }
void addPropertyChangeListener(PropertyChangeListener listener) { throw new Error("not implemented"); }
11,914
public void addPropertyChangeListener(PropertyChangeListener l) { throw new Error("not implemented"); }
public void addPropertyChangeListener(PropertyChangeListener l) { listeners.add (listener); }
11,915
public void addResourceBundle(String name) { throw new Error("not implemented"); }
void addResourceBundle(String name) { throw new Error("not implemented"); }
11,916
public void addResourceBundle(String name) { throw new Error("not implemented"); }
public void addResourceBundle(String name) { bundles.addFirst (name); }
11,917
protected void firePropertyChange(String property, Object o, Object n) { throw new Error("not implemented"); }
protected void firePropertyChange(String property, Object o, Object n) { Iterator i = listeners.iterator (); PropertyChangeEvent pce = new PropertyChangeEvent (this, property, o, n); while (i.hasNext ()) { PropertyChangeListener pcl = (PropertyChangeListener) i.next (); pcl.propertyChange (pce); } }
11,918
public Locale getDefaultLocale() { throw new Error("not implemented"); }
public Locale getDefaultLocale() { return defaultLocale; }
11,919
public PropertyChangeListener[] getPropertyChangeListeners() { throw new Error("not implemented"); }
public PropertyChangeListener[] getPropertyChangeListeners() { return (PropertyChangeListener[]) listeners.toArray (); }
11,920
public ComponentUI getUI(JComponent a) { String pp = a.getUIClassID(); ComponentUI p = (ComponentUI) get(pp); if (p == null) getUIError("failed to locate UI:" + pp); return p; }
public ComponentUI getUI(JComponent target) { String pp = a.getUIClassID(); ComponentUI p = (ComponentUI) get(pp); if (p == null) getUIError("failed to locate UI:" + pp); return p; }
11,921
public ComponentUI getUI(JComponent a) { String pp = a.getUIClassID(); ComponentUI p = (ComponentUI) get(pp); if (p == null) getUIError("failed to locate UI:" + pp); return p; }
public ComponentUI getUI(JComponent a) { String pp = a.getUIClassID(); ComponentUI p = (ComponentUI) get(pp); if (p == null) getUIError("failed to locate UI:" + pp); return p; }
11,922
public Class getUIClass(String id, ClassLoader loader) { throw new Error("not implemented"); }
public Class getUIClass(String id, ClassLoader loader) { String className = (String) get (id); if (className == null) return null; try { if (loader != null) return loader.loadClass (className); return Class.forName (className); } catch (Exception e) { return null; } }
11,924
public void removePropertyChangeListener(PropertyChangeListener l) { throw new Error("not implemented"); }
void removePropertyChangeListener(PropertyChangeListener listener) { throw new Error("not implemented"); }
11,926
public void removePropertyChangeListener(PropertyChangeListener l) { throw new Error("not implemented"); }
public void removePropertyChangeListener(PropertyChangeListener l) { listeners.remove (listener); }
11,927
public void removeResourceBundle(String name) { throw new Error("not implemented"); }
void removeResourceBundle(String name) { throw new Error("not implemented"); }
11,928
public void removeResourceBundle(String name) { throw new Error("not implemented"); }
public void removeResourceBundle(String name) { bundles.remove (name); }
11,929