bugged
stringlengths
6
599k
fixed
stringlengths
6
40.8M
__index_level_0__
int64
0
3.24M
public PartialInputStream(RandomAccessFile raf, long start, long len) { this.raf = raf; filepos = start; end = start + len; }
public PartialInputStream(RandomAccessFile raf, long start, long len) { this.raf = raf; filepos = start; end = start + len; }
37,580
public int available() { long amount = end - filepos; if (amount > Integer.MAX_VALUE) return Integer.MAX_VALUE; return (int) amount; }
public int available() { long amount = end - filepos; if (amount > Integer.MAX_VALUE) return Integer.MAX_VALUE; return (int) amount; }
37,581
public int read() throws IOException { if (filepos == end) return -1; synchronized (raf) { raf.seek(filepos++); return raf.read(); } }
public int read() throws IOException { if (filepos == end) return -1; synchronized (raf) { raf.seek(filepos++); return raf.read(); } }
37,582
public int read() throws IOException { if (filepos == end) return -1; synchronized (raf) { raf.seek(filepos++); return raf.read(); } }
public int read() throws IOException { if (filepos == end) return -1; synchronized (raf) { raf.seek(filepos++); return raf.read(); } }
37,583
public int read() throws IOException { if (filepos == end) return -1; synchronized (raf) { raf.seek(filepos++); return raf.read(); } }
public int read() throws IOException { if (filepos == end) return -1; synchronized (raf) { raf.seek(filepos++); return raf.read(); } }
37,584
public long skip(long amount) { if (amount < 0) throw new IllegalArgumentException(); if (amount > end - filepos) amount = end - filepos; filepos += amount; return amount; }
public long skip(long amount) throws IOException { if (amount < 0) throw new IllegalArgumentException(); if (amount > end - filepos) amount = end - filepos; filepos += amount; return amount; }
37,586
public long skip(long amount) { if (amount < 0) throw new IllegalArgumentException(); if (amount > end - filepos) amount = end - filepos; filepos += amount; return amount; }
public long skip(long amount) { if (amount < 0) throw new IllegalArgumentException(); if (amount > end - filepos) amount = end - filepos; filepos += amount; return amount; }
37,587
private void checkZipFile() throws IOException, ZipException { byte[] magicBuf = new byte[4]; boolean validRead = true; try { raf.readFully(magicBuf); } catch (EOFException eof) { validRead = false; } if (validRead == false || readLeInt(magicBuf, 0) != LOCSIG) { raf.close(...
private void checkZipFile() throws ZipException { byte[] magicBuf = new byte[4]; boolean validRead = true; try { raf.readFully(magicBuf); } catch (EOFException eof) { validRead = false; } if (validRead == false || readLeInt(magicBuf, 0) != LOCSIG) { raf.close(); throw new ...
37,588
private void checkZipFile() throws IOException, ZipException { byte[] magicBuf = new byte[4]; boolean validRead = true; try { raf.readFully(magicBuf); } catch (EOFException eof) { validRead = false; } if (validRead == false || readLeInt(magicBuf, 0) != LOCSIG) { raf.close(...
private void checkZipFile() throws IOException, ZipException { byte[] magicBuf = new byte[4]; boolean validRead = true; try { raf.readFully(magicBuf); } catch (EOFException eof) { validRead = false; } if (validRead == false || readLeInt(magicBuf, 0) != LOCSIG) { raf.close(...
37,589
private void checkZipFile() throws IOException, ZipException { byte[] magicBuf = new byte[4]; boolean validRead = true; try { raf.readFully(magicBuf); } catch (EOFException eof) { validRead = false; } if (validRead == false || readLeInt(magicBuf, 0) != LOCSIG) { raf.close(...
private void checkZipFile() throws IOException, ZipException { byte[] magicBuf = new byte[4]; boolean validRead = true; try { byte[] buf = new byte[4]; raf.readFully(buf); int sig = buf[0] & 0xFF | ((buf[1] & 0xFF) << 8) | ((buf[2] & 0xFF) << 16) | ((buf[3] & 0xFF) << 24); valid = sig == LOCSIG; ...
37,590
private void checkZipFile() throws IOException, ZipException { byte[] magicBuf = new byte[4]; boolean validRead = true; try { raf.readFully(magicBuf); } catch (EOFException eof) { validRead = false; } if (validRead == false || readLeInt(magicBuf, 0) != LOCSIG) { raf.close(...
private void checkZipFile() throws IOException, ZipException { byte[] magicBuf = new byte[4]; boolean validRead = true; try { raf.readFully(magicBuf); } catch (IOException _) { validRead = false; } if (validRead == false || readLeInt(magicBuf, 0) != LOCSIG) { raf.close(); ...
37,591
private void checkZipFile() throws IOException, ZipException { byte[] magicBuf = new byte[4]; boolean validRead = true; try { raf.readFully(magicBuf); } catch (EOFException eof) { validRead = false; } if (validRead == false || readLeInt(magicBuf, 0) != LOCSIG) { raf.close(...
private void checkZipFile() throws IOException, ZipException { byte[] magicBuf = new byte[4]; boolean validRead = true; try { raf.readFully(magicBuf); } catch (EOFException eof) { } if (validRead == false || readLeInt(magicBuf, 0) != LOCSIG) { raf.close(); throw new ZipExc...
37,592
private void checkZipFile() throws IOException, ZipException { byte[] magicBuf = new byte[4]; boolean validRead = true; try { raf.readFully(magicBuf); } catch (EOFException eof) { validRead = false; } if (validRead == false || readLeInt(magicBuf, 0) != LOCSIG) { raf.close(...
private void checkZipFile() throws IOException, ZipException { byte[] magicBuf = new byte[4]; boolean validRead = true; try { raf.readFully(magicBuf); } catch (EOFException eof) { validRead = false; } if (!valid) { try { raf.close(); throw new ZipException("Not a valid zip...
37,593
public InputStream getInputStream(ZipEntry entry) throws IOException { checkClosed(); HashMap entries = getEntries(); String name = entry.getName(); ZipEntry zipEntry = (ZipEntry) entries.get(name); if (zipEntry == null) return null; long start = checkLocalHeader(zipEntry); int method = zipEntry.getMet...
public InputStream getInputStream(ZipEntry entry) throws IOException { checkClosed(); HashMap entries = getEntries(); String name = entry.getName(); ZipEntry zipEntry = (ZipEntry) entries.get(name); if (zipEntry == null) return null; long start = checkLocalHeader(zipEntry); int method = zipEntry.getMet...
37,595
public InputStream getInputStream(ZipEntry entry) throws IOException { checkClosed(); HashMap entries = getEntries(); String name = entry.getName(); ZipEntry zipEntry = (ZipEntry) entries.get(name); if (zipEntry == null) return null; long start = checkLocalHeader(zipEntry); int method = zipEntry.getMet...
public InputStream getInputStream(ZipEntry entry) throws IOException { checkClosed(); HashMap entries = getEntries(); String name = entry.getName(); ZipEntry zipEntry = (ZipEntry) entries.get(name); if (zipEntry == null) return null; long start = checkLocalHeader(zipEntry); int method = zipEntry.getMet...
37,596
public InputStream getInputStream(ZipEntry entry) throws IOException { checkClosed(); HashMap entries = getEntries(); String name = entry.getName(); ZipEntry zipEntry = (ZipEntry) entries.get(name); if (zipEntry == null) return null; long start = checkLocalHeader(zipEntry); int method = zipEntry.getMet...
public InputStream getInputStream(ZipEntry entry) throws IOException { checkClosed(); HashMap entries = getEntries(); String name = entry.getName(); ZipEntry zipEntry = (ZipEntry) entries.get(name); if (zipEntry == null) return null; long start = checkLocalHeader(zipEntry); int method = zipEntry.getMet...
37,597
public InputStream getInputStream(ZipEntry entry) throws IOException { checkClosed(); HashMap entries = getEntries(); String name = entry.getName(); ZipEntry zipEntry = (ZipEntry) entries.get(name); if (zipEntry == null) return null; long start = checkLocalHeader(zipEntry); int method = zipEntry.getMet...
public InputStream getInputStream(ZipEntry entry) throws IOException { checkClosed(); HashMap entries = getEntries(); String name = entry.getName(); ZipEntry zipEntry = (ZipEntry) entries.get(name); if (zipEntry == null) return null; long start = checkLocalHeader(zipEntry); int method = zipEntry.getMet...
37,598
private void readEntries() throws ZipException, IOException { /* Search for the End Of Central Directory. When a zip comment is * present the directory may start earlier. * FIXME: This searches the whole file in a very slow manner if the * file isn't a zip file. */ long pos = raf.length() - ENDHDR; byte...
private void readEntries() throws ZipException, IOException { /* Search for the End Of Central Directory. When a zip comment is * present the directory may start earlier. * FIXME: This searches the whole file in a very slow manner if the * file isn't a zip file. */ long pos = raf.length() - ENDHDR; byte...
37,599
private void readEntries() throws ZipException, IOException { /* Search for the End Of Central Directory. When a zip comment is * present the directory may start earlier. * FIXME: This searches the whole file in a very slow manner if the * file isn't a zip file. */ long pos = raf.length() - ENDHDR; byte...
private void readEntries() throws ZipException, IOException { /* Search for the End Of Central Directory. When a zip comment is * present the directory may start earlier. * FIXME: This searches the whole file in a very slow manner if the * file isn't a zip file. */ long pos = raf.length() - ENDHDR; long...
37,600
private void readEntries() throws ZipException, IOException { /* Search for the End Of Central Directory. When a zip comment is * present the directory may start earlier. * FIXME: This searches the whole file in a very slow manner if the * file isn't a zip file. */ long pos = raf.length() - ENDHDR; byte...
private void readEntries() throws ZipException, IOException { /* Search for the End Of Central Directory. When a zip comment is * present the directory may start earlier. * FIXME: This searches the whole file in a very slow manner if the * file isn't a zip file. */ long pos = raf.length() - ENDHDR; byte...
37,601
private void readEntries() throws ZipException, IOException { /* Search for the End Of Central Directory. When a zip comment is * present the directory may start earlier. * FIXME: This searches the whole file in a very slow manner if the * file isn't a zip file. */ long pos = raf.length() - ENDHDR; byte...
private void readEntries() throws ZipException, IOException { /* Search for the End Of Central Directory. When a zip comment is * present the directory may start earlier. * FIXME: This searches the whole file in a very slow manner if the * file isn't a zip file. */ long pos = raf.length() - ENDHDR; byte...
37,602
private void readEntries() throws ZipException, IOException { /* Search for the End Of Central Directory. When a zip comment is * present the directory may start earlier. * FIXME: This searches the whole file in a very slow manner if the * file isn't a zip file. */ long pos = raf.length() - ENDHDR; byte...
private void readEntries() throws ZipException, IOException { /* Search for the End Of Central Directory. When a zip comment is * present the directory may start earlier. * FIXME: This searches the whole file in a very slow manner if the * file isn't a zip file. */ long pos = raf.length() - ENDHDR; byte...
37,603
private void readEntries() throws ZipException, IOException { /* Search for the End Of Central Directory. When a zip comment is * present the directory may start earlier. * FIXME: This searches the whole file in a very slow manner if the * file isn't a zip file. */ long pos = raf.length() - ENDHDR; byte...
private void readEntries() throws ZipException, IOException { /* Search for the End Of Central Directory. When a zip comment is * present the directory may start earlier. * FIXME: This searches the whole file in a very slow manner if the * file isn't a zip file. */ long pos = raf.length() - ENDHDR; byte...
37,604
private void readEntries() throws ZipException, IOException { /* Search for the End Of Central Directory. When a zip comment is * present the directory may start earlier. * FIXME: This searches the whole file in a very slow manner if the * file isn't a zip file. */ long pos = raf.length() - ENDHDR; byte...
private void readEntries() throws ZipException, IOException { /* Search for the End Of Central Directory. When a zip comment is * present the directory may start earlier. * FIXME: This searches the whole file in a very slow manner if the * file isn't a zip file. */ long pos = raf.length() - ENDHDR; byte...
37,605
private void readEntries() throws ZipException, IOException { /* Search for the End Of Central Directory. When a zip comment is * present the directory may start earlier. * FIXME: This searches the whole file in a very slow manner if the * file isn't a zip file. */ long pos = raf.length() - ENDHDR; byte...
private void readEntries() throws ZipException, IOException { /* Search for the End Of Central Directory. When a zip comment is * present the directory may start earlier. * FIXME: This searches the whole file in a very slow manner if the * file isn't a zip file. */ long pos = raf.length() - ENDHDR; byte...
37,606
private void readEntries() throws ZipException, IOException { /* Search for the End Of Central Directory. When a zip comment is * present the directory may start earlier. * FIXME: This searches the whole file in a very slow manner if the * file isn't a zip file. */ long pos = raf.length() - ENDHDR; byte...
private void readEntries() throws ZipException, IOException { /* Search for the End Of Central Directory. When a zip comment is * present the directory may start earlier. * FIXME: This searches the whole file in a very slow manner if the * file isn't a zip file. */ long pos = raf.length() - ENDHDR; byte...
37,607
private void readEntries() throws ZipException, IOException { /* Search for the End Of Central Directory. When a zip comment is * present the directory may start earlier. * FIXME: This searches the whole file in a very slow manner if the * file isn't a zip file. */ long pos = raf.length() - ENDHDR; byte...
private void readEntries() throws ZipException, IOException { /* Search for the End Of Central Directory. When a zip comment is * present the directory may start earlier. * FIXME: This searches the whole file in a very slow manner if the * file isn't a zip file. */ long pos = raf.length() - ENDHDR; byte...
37,608
private void readEntries() throws ZipException, IOException { /* Search for the End Of Central Directory. When a zip comment is * present the directory may start earlier. * FIXME: This searches the whole file in a very slow manner if the * file isn't a zip file. */ long pos = raf.length() - ENDHDR; byte...
private void readEntries() throws ZipException, IOException { /* Search for the End Of Central Directory. When a zip comment is * present the directory may start earlier. * FIXME: This searches the whole file in a very slow manner if the * file isn't a zip file. */ long pos = raf.length() - ENDHDR; byte...
37,609
private void readEntries() throws ZipException, IOException { /* Search for the End Of Central Directory. When a zip comment is * present the directory may start earlier. * FIXME: This searches the whole file in a very slow manner if the * file isn't a zip file. */ long pos = raf.length() - ENDHDR; byte...
private void readEntries() throws ZipException, IOException { /* Search for the End Of Central Directory. When a zip comment is * present the directory may start earlier. * FIXME: This searches the whole file in a very slow manner if the * file isn't a zip file. */ long pos = raf.length() - ENDHDR; byte...
37,610
private void readEntries() throws ZipException, IOException { /* Search for the End Of Central Directory. When a zip comment is * present the directory may start earlier. * FIXME: This searches the whole file in a very slow manner if the * file isn't a zip file. */ long pos = raf.length() - ENDHDR; byte...
private void readEntries() throws ZipException, IOException { /* Search for the End Of Central Directory. When a zip comment is * present the directory may start earlier. * FIXME: This searches the whole file in a very slow manner if the * file isn't a zip file. */ long pos = raf.length() - ENDHDR; byte...
37,611
private void readEntries() throws ZipException, IOException { /* Search for the End Of Central Directory. When a zip comment is * present the directory may start earlier. * FIXME: This searches the whole file in a very slow manner if the * file isn't a zip file. */ long pos = raf.length() - ENDHDR; byte...
private void readEntries() throws ZipException, IOException { /* Search for the End Of Central Directory. When a zip comment is * present the directory may start earlier. * FIXME: This searches the whole file in a very slow manner if the * file isn't a zip file. */ long pos = raf.length() - ENDHDR; byte...
37,612
public NotBoundException(String s) { super(s); }
public NotBoundException() { super(s); }
37,613
public NotBoundException(String s) { super(s); }
public NotBoundException(String s) { }
37,614
ArcIterator(Arc2D a, AffineTransform xform) { this.xform = xform; x = a.getX(); y = a.getY(); w = a.getWidth(); h = a.getHeight(); angExtDeg = a.getAngleExtent(); startAngRad = a.getAngleStart() * (Math.PI / 180); extentAngRad = angExtDeg * (Math.PI / 180); type = a.getArcType(); double e = extent...
ArcIterator(Arc2D a, AffineTransform xform) { this.xform = xform; x = a.getX(); y = a.getY(); w = a.getWidth(); h = a.getHeight(); angExtDeg = a.getAngleExtent(); startAngRad = a.getAngleStart() * (Math.PI / 180); extentAngRad = angExtDeg * (Math.PI / 180); type = a.getArcType(); double e = extent...
37,615
ArcIterator(Arc2D a, AffineTransform xform) { this.xform = xform; x = a.getX(); y = a.getY(); w = a.getWidth(); h = a.getHeight(); angExtDeg = a.getAngleExtent(); startAngRad = a.getAngleStart() * (Math.PI / 180); extentAngRad = angExtDeg * (Math.PI / 180); type = a.getArcType(); double e = extent...
ArcIterator(Arc2D a, AffineTransform xform) { this.xform = xform; x = a.getX(); y = a.getY(); w = a.getWidth(); h = a.getHeight(); angExtDeg = a.getAngleExtent(); startAngRad = a.getAngleStart() * (Math.PI / 180); extentAngRad = angExtDeg * (Math.PI / 180); type = a.getArcType(); double e = extent...
37,616
ArcIterator(Arc2D a, AffineTransform xform) { this.xform = xform; x = a.getX(); y = a.getY(); w = a.getWidth(); h = a.getHeight(); angExtDeg = a.getAngleExtent(); startAngRad = a.getAngleStart() * (Math.PI / 180); extentAngRad = angExtDeg * (Math.PI / 180); type = a.getArcType(); double e = extent...
ArcIterator(Arc2D a, AffineTransform xform) { this.xform = xform; x = a.getX(); y = a.getY(); w = a.getWidth(); h = a.getHeight(); angExtDeg = a.getAngleExtent(); startAngRad = a.getAngleStart() * (Math.PI / 180); extentAngRad = angExtDeg * (Math.PI / 180); type = a.getArcType(); double e = extent...
37,617
ArcIterator(Arc2D a, AffineTransform xform) { this.xform = xform; x = a.getX(); y = a.getY(); w = a.getWidth(); h = a.getHeight(); angExtDeg = a.getAngleExtent(); startAngRad = a.getAngleStart() * (Math.PI / 180); extentAngRad = angExtDeg * (Math.PI / 180); type = a.getArcType(); double e = extent...
ArcIterator(Arc2D a, AffineTransform xform) { this.xform = xform; x = a.getX(); y = a.getY(); w = a.getWidth(); h = a.getHeight(); angExtDeg = a.getAngleExtent(); startAngRad = a.getAngleStart() * (Math.PI / 180); extentAngRad = angExtDeg * (Math.PI / 180); type = a.getArcType(); double e = extent...
37,618
ArcIterator(Arc2D a, AffineTransform xform) { this.xform = xform; x = a.getX(); y = a.getY(); w = a.getWidth(); h = a.getHeight(); angExtDeg = a.getAngleExtent(); startAngRad = a.getAngleStart() * (Math.PI / 180); extentAngRad = angExtDeg * (Math.PI / 180); type = a.getArcType(); double e = extent...
ArcIterator(Arc2D a, AffineTransform xform) { this.xform = xform; x = a.getX(); y = a.getY(); w = a.getWidth(); h = a.getHeight(); angExtDeg = a.getAngleExtent(); startAngRad = a.getAngleStart() * (Math.PI / 180); extentAngRad = angExtDeg * (Math.PI / 180); type = a.getArcType(); double e = extent...
37,619
ArcIterator(Arc2D a, AffineTransform xform) { this.xform = xform; x = a.getX(); y = a.getY(); w = a.getWidth(); h = a.getHeight(); angExtDeg = a.getAngleExtent(); startAngRad = a.getAngleStart() * (Math.PI / 180); extentAngRad = angExtDeg * (Math.PI / 180); type = a.getArcType(); double e = extent...
ArcIterator(Arc2D a, AffineTransform xform) { this.xform = xform; x = a.getX(); y = a.getY(); w = a.getWidth(); h = a.getHeight(); angExtDeg = a.getAngleExtent(); startAngRad = a.getAngleStart() * (Math.PI / 180); extentAngRad = angExtDeg * (Math.PI / 180); type = a.getArcType(); double e = extent...
37,620
public int currentSegment(float[] coords) { if (current > limit) { throw new NoSuchElementException("arc iterator out of bounds"); } if (current == 0) { coords[0] = (float) (Math.cos(startAngRad) * w + x) / 2; coords[1] = (float) (Math.sin(startAngRad) * h + y) / 2; if (xform != null) { xform.tr...
public int currentSegment(float[] coords) { if (current > limit) { throw new NoSuchElementException("arc iterator out of bounds"); } if (current == 0) { coords[0] = (float) (Math.cos(startAngRad) * w + x) / 2; coords[1] = (float) (Math.sin(startAngRad) * h + y) / 2; if (xform != null) { xform.tr...
37,621
public int getWindingRule() { return WIND_NON_ZERO; }
public int getWindingRule() { return WIND_NON_ZERO; }
37,622
public boolean isDone() { return current > limit; }
public boolean isDone() { return current > limit; }
37,623
public void next() { current++; }
public void next() { current++; }
37,624
public Double() { super(OPEN); }
public Double() { super(OPEN); }
37,625
public double getAngleExtent() { return extent; }
public double getAngleExtent() { return extent; }
37,626
public double getAngleStart() { return start; }
public double getAngleStart() { return start; }
37,627
public double getHeight() { return height; }
public double getHeight() { return height; }
37,628
public double getWidth() { return width; }
public double getWidth() { return width; }
37,629
public double getX() { return x; }
public double getX() { return x; }
37,630
public double getY() { return y; }
public double getY() { return y; }
37,631
public boolean isEmpty() { return width <= 0 || height <= 0; }
public boolean isEmpty() { return width <= 0 || height <= 0; }
37,632
protected Rectangle2D makeBounds(double x, double y, double w, double h) { return new Rectangle2D.Double(x, y, w, h); }
protected Rectangle2D makeBounds(double x, double y, double w, double h) { return new Rectangle2D.Double(x, y, w, h); }
37,633
public void setAngleExtent(double extent) { this.extent = extent; }
public void setAngleExtent(double extent) { this.extent = extent; }
37,634
public void setAngleStart(double start) { this.start = start; }
public void setAngleStart(double start) { this.start = start; }
37,635
public void setArc(double x, double y, double w, double h, double start, double extent, int type) { this.x = x; this.y = y; width = w; height = h; this.start = start; this.extent = extent; setArcType(type); }
public void setArc(double x, double y, double w, double h, double start, double extent, int type) { this.x = x; this.y = y; width = w; height = h; this.start = start; this.extent = extent; setArcType(type); }
37,636
public Float() { super(OPEN); }
public Float() { super(OPEN); }
37,637
public double getAngleExtent() { return extent; }
public double getAngleExtent() { return extent; }
37,638
public double getAngleStart() { return start; }
public double getAngleStart() { return start; }
37,639
public double getHeight() { return height; }
public double getHeight() { return height; }
37,640
public double getWidth() { return width; }
public double getWidth() { return width; }
37,641
public double getX() { return x; }
public double getX() { return x; }
37,642
public double getY() { return y; }
public double getY() { return y; }
37,643
public boolean isEmpty() { return width <= 0 || height <= 0; }
public boolean isEmpty() { return width <= 0 || height <= 0; }
37,644
protected Rectangle2D makeBounds(double x, double y, double w, double h) { return new Rectangle2D.Float((float) x, (float) y, (float) w, (float) h); }
protected Rectangle2D makeBounds(double x, double y, double w, double h) { return new Rectangle2D.Float((float) x, (float) y, (float) w, (float) h); }
37,645
public void setAngleExtent(double extent) { this.extent = (float) extent; }
public void setAngleExtent(double extent) { this.extent = (float) extent; }
37,646
public void setAngleStart(double start) { this.start = (float) start; }
public void setAngleStart(double start) { this.start = (float) start; }
37,647
public void setArc(double x, double y, double w, double h, double start, double extent, int type) { this.x = (float) x; this.y = (float) y; width = (float) w; height = (float) h; this.start = (float) start; this.extent = (float) extent; setArcType(type); }
public void setArc(double x, double y, double w, double h, double start, double extent, int type) { this.x = (float) x; this.y = (float) y; width = (float) w; height = (float) h; this.start = (float) start; this.extent = (float) extent; setArcType(type); }
37,648
protected Arc2D(int type) { if (type < OPEN || type > PIE) throw new IllegalArgumentException(); this.type = type; }
protected Arc2D(int type) { if (type < OPEN || type > PIE) throw new IllegalArgumentException(); this.type = type; }
37,649
public boolean contains(double x, double y) { double w = getWidth(); double h = getHeight(); if (w <= 0 || h <= 0) return false; // XXX Finish implementing. throw new Error("not implemented"); }
public boolean contains(double x, double y) { double w = getWidth(); double h = getHeight(); if (w <= 0 || h <= 0) return false; // XXX Finish implementing. throw new Error("not implemented"); }
37,650
public boolean containsAngle(double a) { // XXX Implement. throw new Error("not implemented"); }
public boolean containsAngle(double a) { // XXX Implement. throw new Error("not implemented"); }
37,651
public int getArcType() { return type; }
public int getArcType() { return type; }
37,652
public Rectangle2D getBounds2D() { double extent = getAngleExtent(); if (Math.abs(extent) >= 360) return makeBounds(getX(), getY(), getWidth(), getHeight()); // XXX Finish implementing. throw new Error("not implemented"); }
public Rectangle2D getBounds2D() { double extent = getAngleExtent(); if (Math.abs(extent) >= 360) return makeBounds(getX(), getY(), getWidth(), getHeight()); // XXX Finish implementing. throw new Error("not implemented"); }
37,653
public Rectangle2D getBounds2D() { double extent = getAngleExtent(); if (Math.abs(extent) >= 360) return makeBounds(getX(), getY(), getWidth(), getHeight()); // XXX Finish implementing. throw new Error("not implemented"); }
public Rectangle2D getBounds2D() { double extent = getAngleExtent(); if (Math.abs(extent) >= 360) return makeBounds(getX(), getY(), getWidth(), getHeight()); // XXX Finish implementing. throw new Error("not implemented"); }
37,654
public Point2D getEndPoint() { double angle = (getAngleStart() + getAngleExtent()) * (-180 / Math.PI); double x = (Math.cos(angle) * getWidth() + getX()) / 2; double y = (Math.sin(angle) * getHeight() + getY()) / 2; return new Point2D.Double(x, y); }
public Point2D getEndPoint() { double angle = (getAngleStart() + getAngleExtent()) * (-180 / Math.PI); double x = (Math.cos(angle) * getWidth() + getX()) / 2; double y = (Math.sin(angle) * getHeight() + getY()) / 2; return new Point2D.Double(x, y); }
37,655
public PathIterator getPathIterator(AffineTransform at) { return new ArcIterator(this, at); }
public PathIterator getPathIterator(AffineTransform at) { return new ArcIterator(this, at); }
37,656
public Point2D getStartPoint() { double angle = getAngleStart() * (-180 / Math.PI); double x = (Math.cos(angle) * getWidth() + getX()) / 2; double y = (Math.sin(angle) * getHeight() + getY()) / 2; return new Point2D.Double(x, y); }
public Point2D getStartPoint() { double angle = getAngleStart() * (-180 / Math.PI); double x = (Math.cos(angle) * getWidth() + getX()) / 2; double y = (Math.sin(angle) * getHeight() + getY()) / 2; return new Point2D.Double(x, y); }
37,657
public boolean intersects(double x, double y, double w, double h) { double mw = getWidth(); double mh = getHeight(); if (mw <= 0 || mh <= 0 || w <= 0 || h <= 0) return false; // XXX Finish implementing. throw new Error("not implemented"); }
public boolean intersects(double x, double y, double w, double h) { double mw = getWidth(); double mh = getHeight(); if (mw <= 0 || mh <= 0 || w <= 0 || h <= 0) return false; // XXX Finish implementing. throw new Error("not implemented"); }
37,658
protected abstract Rectangle2D makeBounds(double x, double y, double w, double h);
protected abstract Rectangle2D makeBounds(double x, double y, double w, double h);
37,659
public void setAngles(double x1, double y1, double x2, double y2) { // Normalize the points. double mx = getX(); double my = getY(); double mw = getWidth(); double mh = getHeight(); x1 = ((x1 * 2) - mx) / mw; y1 = ((y1 * 2) - my) / mh; x2 = ((x2 * 2) - mx) / mw; y2 = ((y2 * 2) - my) / mh; double start = Math...
public void setAngles(double x1, double y1, double x2, double y2) { // Normalize the points. double mx = getX(); double my = getY(); double mw = getWidth(); double mh = getHeight(); x1 = ((x1 * 2) - mx) / mw; y1 = ((y1 * 2) - my) / mh; x2 = ((x2 * 2) - mx) / mw; y2 = ((y2 * 2) - my) / mh; double start = Math...
37,660
public void setAngles(double x1, double y1, double x2, double y2) { // Normalize the points. double mx = getX(); double my = getY(); double mw = getWidth(); double mh = getHeight(); x1 = ((x1 * 2) - mx) / mw; y1 = ((y1 * 2) - my) / mh; x2 = ((x2 * 2) - mx) / mw; y2 = ((y2 * 2) - my) / mh; double start = Math...
public void setAngles(double x1, double y1, double x2, double y2) { // Normalize the points. double mx = getX(); double my = getY(); double mw = getWidth(); double mh = getHeight(); x1 = ((x1 * 2) - mx) / mw; y1 = ((y1 * 2) - my) / mh; x2 = ((x2 * 2) - mx) / mw; y2 = ((y2 * 2) - my) / mh; double start = Math...
37,661
public abstract void setArc(double x, double y, double w, double h, double start, double extent, int type);
public abstract void setArc(double x, double y, double w, double h, double start, double extent, int type);
37,662
public void setArcByCenter(double x, double y, double r, double start, double extent, int type) { setArc(x - r, y - r, r + r, r + r, start, extent, type); }
public void setArcByCenter(double x, double y, double r, double start, double extent, int type) { setArc(x - r, y - r, r + r, r + r, start, extent, type); }
37,663
public void setArcByTangent(Point2D p1, Point2D p2, Point2D p3, double r) { // XXX Implement. throw new Error("not implemented"); }
public void setArcByTangent(Point2D p1, Point2D p2, Point2D p3, double r) { // XXX Implement. throw new Error("not implemented"); }
37,664
public void setArcType(int type) { if (type < OPEN || type > PIE) throw new IllegalArgumentException(); this.type = type; }
public void setArcType(int type) { if (type < OPEN || type > PIE) throw new IllegalArgumentException(); this.type = type; }
37,665
public void setFrame(double x, double y, double w, double h) { setArc(x, y, w, h, getAngleStart(), getAngleExtent(), type); }
public void setFrame(double x, double y, double w, double h) { setArc(x, y, w, h, getAngleStart(), getAngleExtent(), type); }
37,666
public Double() { }
public Double() { }
37,667
public Rectangle2D getBounds2D() { double x = Math.min(x1, x2); double y = Math.min(y1, y2); double w = Math.abs(x1 - x2); double h = Math.abs(y1 - y2); return new Rectangle2D.Double(x, y, w, h); }
public Rectangle2D getBounds2D() { double x = Math.min(x1, x2); double y = Math.min(y1, y2); double w = Math.abs(x1 - x2); double h = Math.abs(y1 - y2); return new Rectangle2D.Double(x, y, w, h); }
37,668
public Point2D getP1() { return new Point2D.Double(x1, y1); }
public Point2D getP1() { return new Point2D.Double(x1, y1); }
37,669
public Point2D getP2() { return new Point2D.Double(x2, y2); }
public Point2D getP2() { return new Point2D.Double(x2, y2); }
37,670
public double getX1() { return x1; }
public double getX1() { return x1; }
37,671
public double getX2() { return x2; }
public double getX2() { return x2; }
37,672
public double getY1() { return y1; }
public double getY1() { return y1; }
37,673
public double getY2() { return y2; }
public double getY2() { return y2; }
37,674
public void setLine(double x1, double y1, double x2, double y2) { this.x1 = x1; this.y1 = y1; this.x2 = x2; this.y2 = y2; }
public void setLine(double x1, double y1, double x2, double y2) { this.x1 = x1; this.y1 = y1; this.x2 = x2; this.y2 = y2; }
37,675
public Float() { }
public Float() { }
37,676
public Rectangle2D getBounds2D() { float x = Math.min(x1, x2); float y = Math.min(y1, y2); float w = Math.abs(x1 - x2); float h = Math.abs(y1 - y2); return new Rectangle2D.Float(x, y, w, h); }
public Rectangle2D getBounds2D() { float x = Math.min(x1, x2); float y = Math.min(y1, y2); float w = Math.abs(x1 - x2); float h = Math.abs(y1 - y2); return new Rectangle2D.Float(x, y, w, h); }
37,677
public Point2D getP1() { return new Point2D.Float(x1, y1); }
public Point2D getP1() { return new Point2D.Float(x1, y1); }
37,678
public Point2D getP2() { return new Point2D.Float(x2, y2); }
public Point2D getP2() { return new Point2D.Float(x2, y2); }
37,679
public double getX1() { return x1; }
public double getX1() { return x1; }
37,680
public double getX2() { return x2; }
public double getX2() { return x2; }
37,681