bugged stringlengths 6 599k | fixed stringlengths 6 40.8M | __index_level_0__ int64 0 3.24M |
|---|---|---|
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); ... | 18,944 |
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); ... | 18,945 |
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); ... | 18,946 |
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); ... | 18,947 |
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); ... | 18,948 |
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); ... | 18,949 |
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.getTimeInMillis() == getTimeInMillis()); } | 18,950 |
public MetalButtonUI() { super(); focusColor = getFocusColor(); selectColor = getSelectColor(); disabledTextColor = getDisabledTextColor(); } | public MetalButtonUI() { super(); focusColor = getFocusColor(); selectColor = getSelectColor(); disabledTextColor = getDisabledTextColor(); } | 18,951 |
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; } | 18,952 |
protected Color getDisabledTextColor() { UIDefaults def = UIManager.getLookAndFeelDefaults(); return def.getColor(getPropertyPrefix() + ".disabledText"); } | protected Color getDisabledTextColor() { UIDefaults def = UIManager.getLookAndFeelDefaults(); return def.getColor(getPropertyPrefix() + ".disabledText"); } | 18,953 |
protected Color getFocusColor() { UIDefaults def = UIManager.getLookAndFeelDefaults(); return def.getColor(getPropertyPrefix() + ".focus"); } | protected Color getFocusColor() { UIDefaults def = UIManager.getLookAndFeelDefaults(); return def.getColor(getPropertyPrefix() + ".focus"); } | 18,954 |
protected Color getSelectColor() { UIDefaults def = UIManager.getLookAndFeelDefaults(); return def.getColor(getPropertyPrefix() + ".select"); } | protected Color getSelectColor() { UIDefaults def = UIManager.getLookAndFeelDefaults(); return def.getColor(getPropertyPrefix() + ".select"); } | 18,955 |
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()); } | 18,956 |
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... | 18,957 |
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... | 18,958 |
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) 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... | 18,959 |
public synchronized String substring(int beginIndex, int endIndex) { int len = endIndex - beginIndex; if (beginIndex < 0 || endIndex > count || endIndex < beginIndex) throw new StringIndexOutOfBoundsException(); if (len == 0) return ""; // Don't copy unless substring is smaller than 1/4 of the ... | public String substring(int beginIndex) { int len = endIndex - beginIndex; if (beginIndex < 0 || endIndex > count || endIndex < beginIndex) throw new StringIndexOutOfBoundsException(); if (len == 0) return ""; // Don't copy unless substring is smaller than 1/4 of the buffer. boolean share_bu... | 18,961 |
public synchronized String substring(int beginIndex, int endIndex) { int len = endIndex - beginIndex; if (beginIndex < 0 || endIndex > count || endIndex < beginIndex) throw new StringIndexOutOfBoundsException(); if (len == 0) return ""; // Don't copy unless substring is smaller than 1/4 of the ... | public synchronized String substring(int beginIndex, int endIndex) { int len = endIndex - beginIndex; if (beginIndex < 0 || endIndex > count || endIndex < beginIndex) throw new StringIndexOutOfBoundsException(); if (len == 0) return ""; // Don't copy unless substring is smaller than 1/4 of the ... | 18,962 |
public void paint(Graphics g, JComponent c) { JToolTip tip = (JToolTip) c; String text = tip.getTipText(); Toolkit t = tip.getToolkit(); if (text == null) return; Rectangle vr = new Rectangle(); vr = SwingUtilities.calculateInnerArea(tip, vr); Rectangle ir = new Rectangle(); Rectangle tr... | public void paint(Graphics g, JComponent c) { JToolTip tip = (JToolTip) c; String text = tip.getTipText(); Toolkit t = tip.getToolkit(); if (text == null) return; Rectangle vr = new Rectangle(); vr = SwingUtilities.calculateInnerArea(tip, vr); Rectangle ir = new Rectangle(); Rectangle tr... | 18,963 |
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); } ... | 18,965 |
public float getLSB () throws NotImplementedException { throw new Error ("not implemented"); } | public float getLSB () throws NotImplementedException { throw new Error ("not implemented"); } | 18,966 |
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(); } | 18,967 |
public float getRSB () throws NotImplementedException { throw new Error ("not implemented"); } | public float getRSB () throws NotImplementedException { throw new Error ("not implemented"); } | 18,968 |
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())); } | 18,969 |
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; } | 18,970 |
public ServerSocketChannel(SelectorProvider provider) { super(provider); } | public ServerSocketChannel(SelectorProvider provider) { super(provider); } | 18,971 |
protected final void begin () { } | protected final void begin() { } | 18,972 |
protected final void end (boolean completed) throws AsynchronousCloseException { } | protected final void end(boolean completed) throws AsynchronousCloseException { } | 18,973 |
public void actionPerformed(ActionEvent ev) { caret.setVisible(!caret.isVisible()); } | public void actionPerformed(ActionEvent ev) { Caret c = caret; if (c != null) c.setVisible(!c.isVisible()); } | 18,975 |
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); } | 18,976 |
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); } } | 18,977 |
public SignedObject(Serializable object, PrivateKey signingKey, Signature signingEngine) throws IOException, InvalidKeyException, SignatureException { thealgorithm = signingEngine.getAlgorithm(); ByteArrayOutputStream ostream = new ByteArrayOutputStream(); ObjectOutputStream p = new ObjectOutputSt... | public SignedObject(Serializable object, PrivateKey signingKey, Signature signingEngine) throws IOException, InvalidKeyException, SignatureException { thealgorithm = signingEngine.getAlgorithm(); ByteArrayOutputStream ostream = new ByteArrayOutputStream(); ObjectOutputStream p = new ObjectOutputSt... | 18,978 |
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(); } | 18,980 |
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; } | 18,981 |
public byte[] getSignature() { return signature; } | public byte[] getSignature() { return (byte[]) signature.clone(); } | 18,982 |
public boolean verify(PublicKey verificationKey, Signature verificationEngine) throws InvalidKeyException, SignatureException { verificationEngine.initVerify(verificationKey); verificationEngine.update(content); return verificationEngine.verify(signature); } | public boolean verify(PublicKey verificationKey, Signature verificationEngine) throws InvalidKeyException, SignatureException { verificationEngine.initVerify(verificationKey); verificationEngine.update(content); return verificationEngine.verify(signature); } | 18,983 |
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_... | 18,984 |
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; } | 18,985 |
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... | 18,986 |
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 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()); // IB... | 18,987 |
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; } | 18,989 |
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; } | 18,990 |
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; } | 18,991 |
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; } | 18,992 |
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; } | 18,993 |
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; } | 18,994 |
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; } | 18,995 |
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; } | 18,996 |
public void paintImmediately(Rectangle r) { Component root = SwingUtilities.getRoot(this); if (root == null || ! root.isShowing()) return; Graphics g = root.getGraphics(); if (g == null) return; Rectangle clip = SwingUtilities.convertRectangle(this, r, root); g.setClip(clip); root.paint(... | public void paintImmediately(Rectangle r) { Component root = SwingUtilities.getRoot(this); if (root == null || ! root.isShowing()) return; Graphics g = root.getGraphics(); if (g == null) return; Rectangle clip = SwingUtilities.convertRectangle(this, r, root); g.setClip(clip); root.paint(... | 18,997 |
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, byte[] data) { this.fs = fs; this.data = new byte[INODE_LENGTH]; System.arraycopy(data, 0, this.data, 0, INODE_LENGTH); } | 18,998 |
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... | 19,000 |
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); log.debug("INode.getIMode(): "+NumberUtils.hex(iMode)); return iMode; } | 19,001 |
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, 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); } | 19,002 |
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... | 19,003 |
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; } | 19,004 |
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; } | 19,005 |
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); } | 19,006 |
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), ... | 19,007 |
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; } | 19,009 |
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; } } }; } | 19,010 |
public Object createValue(UIDefaults table) { throw new Error("not implemented"); } | public Object createValue (UIDefaults table) { throw new Error("not implemented"); } | 19,011 |
public Object createValue(UIDefaults table) { throw new Error("not implemented"); } | public Object createValue(UIDefaults table) { return inner.createValue (table); } | 19,012 |
public void addPropertyChangeListener(PropertyChangeListener l) { throw new Error("not implemented"); } | void addPropertyChangeListener(PropertyChangeListener listener) { throw new Error("not implemented"); } | 19,013 |
public void addPropertyChangeListener(PropertyChangeListener l) { throw new Error("not implemented"); } | public void addPropertyChangeListener(PropertyChangeListener l) { listeners.add (listener); } | 19,014 |
public void addResourceBundle(String name) { throw new Error("not implemented"); } | void addResourceBundle(String name) { throw new Error("not implemented"); } | 19,015 |
public void addResourceBundle(String name) { throw new Error("not implemented"); } | public void addResourceBundle(String name) { bundles.addFirst (name); } | 19,016 |
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); } } | 19,017 |
public Locale getDefaultLocale() { throw new Error("not implemented"); } | public Locale getDefaultLocale() { return defaultLocale; } | 19,018 |
public PropertyChangeListener[] getPropertyChangeListeners() { throw new Error("not implemented"); } | public PropertyChangeListener[] getPropertyChangeListeners() { return (PropertyChangeListener[]) listeners.toArray (); } | 19,019 |
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; } | 19,020 |
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; } | 19,021 |
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; } } | 19,023 |
protected void getUIError(String msg) { // Does nothing unless overridden. } | System.err.println ("UIDefaults.getUIError: " + msg); System.err.println ("UIDefaults.getUIError: " + msg); protectedSystem.err.println ("UIDefaults.getUIError: " + msg); voidSystem.err.println ("UIDefaults.getUIError: " + msg); getUIError(StringSystem.err.println ("UIDefaults.getUIError: " + msg); msg)System.err.print... | 19,024 |
public void removePropertyChangeListener(PropertyChangeListener l) { throw new Error("not implemented"); } | void removePropertyChangeListener(PropertyChangeListener listener) { throw new Error("not implemented"); } | 19,025 |
public void removePropertyChangeListener(PropertyChangeListener l) { throw new Error("not implemented"); } | public void removePropertyChangeListener(PropertyChangeListener l) { listeners.remove (listener); } | 19,026 |
public void removeResourceBundle(String name) { throw new Error("not implemented"); } | void removeResourceBundle(String name) { throw new Error("not implemented"); } | 19,027 |
public void removeResourceBundle(String name) { throw new Error("not implemented"); } | public void removeResourceBundle(String name) { bundles.remove (name); } | 19,028 |
public void setDefaultLocale(Locale l) { throw new Error("not implemented"); } | void setDefaultLocale(Locale loc) { throw new Error("not implemented"); } | 19,029 |
public void setDefaultLocale(Locale l) { throw new Error("not implemented"); } | public void setDefaultLocale(Locale l) { defaultLocale = loc; } | 19,030 |
public Dictionary getDocumentProperties() { return null; } | public Dictionary getDocumentProperties() { if (properties == null) properties = new Hashtable(); return properties; } | 19,031 |
public Object getProperty(Object key) { return null; } | public Object getProperty(Object key) { Object value = null; if (properties != null) value = properties.get(key); return value; } | 19,032 |
protected AccessibleJPopupMenu(JPopupMenu component) { super(component); // TODO } // AccessibleJPopupMenu() | protected AccessibleJPopupMenu(JPopupMenu component) { super(component); // TODO } // AccessibleJPopupMenu() | 19,035 |
public AccessibleRole getAccessibleRole() { return AccessibleRole.POPUP_MENU; } // getAccessibleRole() | public AccessibleRole getAccessibleRole() { return AccessibleRole.POPUP_MENU; } // getAccessibleRole() | 19,036 |
public Separator() { // TODO } // Separator() | public Separator() { // TODO } // Separator() | 19,037 |
public String getUIClassID() { return null; // TODO } // getUIClassID() | public String getUIClassID() { return null; // TODO } // getUIClassID() | 19,038 |
public JPopupMenu() { // TODO } // JPopupMenu() | public JPopupMenu() { // TODO } // JPopupMenu() | 19,039 |
public JMenuItem add(JMenuItem item) { return null; // TODO } // add() | public JMenuItem add(JMenuItem item) { return null; // TODO } // add() | 19,040 |
public void addPopupMenuListener(PopupMenuListener listener) { // TODO } // addPopupMenuListener() | public void addPopupMenuListener(PopupMenuListener listener) { // TODO } // addPopupMenuListener() | 19,041 |
public void addSeparator() { // TODO } // addSeparator() | public void addSeparator() { // TODO } // addSeparator() | 19,042 |
protected PropertyChangeListener createActionChangeListener(JMenuItem item) { return null; // TODO } // createActionChangeListener() | protected PropertyChangeListener createActionChangeListener(JMenuItem item) { return null; // TODO } // createActionChangeListener() | 19,043 |
protected JMenuItem createActionComponent(Action action) { return null; // TODO } // createActionComponent() | protected JMenuItem createActionComponent(Action action) { return null; // TODO } // createActionComponent() | 19,044 |
protected void firePopupMenuCanceled() { // TODO } // firePopupMenuCanceled() | protected void firePopupMenuCanceled() { // TODO } // firePopupMenuCanceled() | 19,045 |
protected void firePopupMenuWillBecomeInvisible() { // TODO } // firePopupMenuWillBecomeInvisible() | protected void firePopupMenuWillBecomeInvisible() { // TODO } // firePopupMenuWillBecomeInvisible() | 19,046 |
protected void firePopupMenuWillBecomeVisible() { // TODO } // firePopupMenuWillBecomeVisible() | protected void firePopupMenuWillBecomeVisible() { // TODO } // firePopupMenuWillBecomeVisible() | 19,047 |
public AccessibleContext getAccessibleContext() { if (accessibleContext == null) { accessibleContext = new AccessibleJPopupMenu(this); } // if return accessibleContext; } // getAccessibleContext() | public AccessibleContext getAccessibleContext() { if (accessibleContext == null) { accessibleContext = new AccessibleJPopupMenu(this); } // if return accessibleContext; } // getAccessibleContext() | 19,048 |
public Component getComponent() { return null; // TODO } // getComponent() | public Component getComponent() { return null; // TODO } // getComponent() | 19,049 |
public Component getComponentAtIndex(int index) { return null; // TODO } // getComponentAtIndex() | public Component getComponentAtIndex(int index) { return null; // TODO } // getComponentAtIndex() | 19,050 |
public int getComponentIndex(Component component) { return 0; // TODO } // getComponentIndex() | public int getComponentIndex(Component component) { return 0; // TODO } // getComponentIndex() | 19,051 |
public static boolean getDefaultLightWeightPopupEnabled() { return false; // TODO } // getDefaultLightWeightPopupEnabled() | public static boolean getDefaultLightWeightPopupEnabled() { return false; // TODO } // getDefaultLightWeightPopupEnabled() | 19,052 |
public Component getInvoker() { return null; // TODO } // getInvoker() | public Component getInvoker() { return null; // TODO } // getInvoker() | 19,053 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.