public class DebugGraphics extends Graphics
NOTE: You must turn off double buffering to use DebugGraphics: RepaintManager repaintManager = RepaintManager.currentManager(component); repaintManager.setDoubleBufferingEnabled(false);
| Modifier and Type | Field and Description |
|---|---|
static int |
BUFFERED_OPTION
Show buffered operations in a separate
Frame . |
static int |
FLASH_OPTION
Flash graphics operations.
|
static int |
LOG_OPTION
Log graphics operations.
|
static int |
NONE_OPTION
Don't debug graphics operations.
|
| Constructor and Description |
|---|
DebugGraphics()
Constructs a new debug graphics context that supports slowed
down drawing.
|
DebugGraphics(Graphics graphics)
Constructs a debug graphics context from an existing graphics
context that supports slowed down drawing.
|
DebugGraphics(Graphics graphics,
JComponent component)
Constructs a debug graphics context from an existing graphics
context that slows down drawing for the specified component.
|
| Modifier and Type | Method and Description |
|---|---|
void |
clearRect(int x,
int y,
int width,
int height)
Overrides
Graphics.clearRect . |
void |
clipRect(int x,
int y,
int width,
int height)
Overrides
Graphics.clipRect . |
void |
copyArea(int x,
int y,
int width,
int height,
int destX,
int destY)
Overrides
Graphics.copyArea . |
Graphics |
create()
Overrides
Graphics.create to return a DebugGraphics object. |
Graphics |
create(int x,
int y,
int width,
int height)
Overrides
Graphics.create to return a DebugGraphics object. |
void |
dispose()
Overrides
Graphics.dispose . |
void |
draw3DRect(int x,
int y,
int width,
int height,
boolean raised)
Overrides
Graphics.draw3DRect . |
void |
drawArc(int x,
int y,
int width,
int height,
int startAngle,
int arcAngle)
Overrides
Graphics.drawArc . |
void |
drawBytes(byte[] data,
int offset,
int length,
int x,
int y)
Overrides
Graphics.drawBytes . |
void |
drawChars(char[] data,
int offset,
int length,
int x,
int y)
Overrides
Graphics.drawChars . |
boolean |
drawImage(Image img,
int x,
int y,
Color bgcolor,
ImageObserver observer)
Overrides
Graphics.drawImage . |
boolean |
drawImage(Image img,
int x,
int y,
ImageObserver observer)
Overrides
Graphics.drawImage . |
boolean |
drawImage(Image img,
int x,
int y,
int width,
int height,
Color bgcolor,
ImageObserver observer)
Overrides
Graphics.drawImage . |
boolean |
drawImage(Image img,
int x,
int y,
int width,
int height,
ImageObserver observer)
Overrides
Graphics.drawImage . |
boolean |
drawImage(Image img,
int dx1,
int dy1,
int dx2,
int dy2,
int sx1,
int sy1,
int sx2,
int sy2,
Color bgcolor,
ImageObserver observer)
Overrides
Graphics.drawImage . |
boolean |
drawImage(Image img,
int dx1,
int dy1,
int dx2,
int dy2,
int sx1,
int sy1,
int sx2,
int sy2,
ImageObserver observer)
Overrides
Graphics.drawImage . |
void |
drawLine(int x1,
int y1,
int x2,
int y2)
Overrides
Graphics.drawLine . |
void |
drawOval(int x,
int y,
int width,
int height)
Overrides
Graphics.drawOval . |
void |
drawPolygon(int[] xPoints,
int[] yPoints,
int nPoints)
Overrides
Graphics.drawPolygon . |
void |
drawPolyline(int[] xPoints,
int[] yPoints,
int nPoints)
Overrides
Graphics.drawPolyline . |
void |
drawRect(int x,
int y,
int width,
int height)
Overrides
Graphics.drawRect . |
void |
drawRoundRect(int x,
int y,
int width,
int height,
int arcWidth,
int arcHeight)
Overrides
Graphics.drawRoundRect . |
void |
drawString(AttributedCharacterIterator iterator,
int x,
int y)
Overrides
Graphics.drawString . |
void |
drawString(String aString,
int x,
int y)
Overrides
Graphics.drawString . |
void |
fill3DRect(int x,
int y,
int width,
int height,
boolean raised)
Overrides
Graphics.fill3DRect . |
void |
fillArc(int x,
int y,
int width,
int height,
int startAngle,
int arcAngle)
Overrides
Graphics.fillArc . |
void |
fillOval(int x,
int y,
int width,
int height)
Overrides
Graphics.fillOval . |
void |
fillPolygon(int[] xPoints,
int[] yPoints,
int nPoints)
Overrides
Graphics.fillPolygon . |
void |
fillRect(int x,
int y,
int width,
int height)
Overrides
Graphics.fillRect . |
void |
fillRoundRect(int x,
int y,
int width,
int height,
int arcWidth,
int arcHeight)
Overrides
Graphics.fillRoundRect . |
static Color |
flashColor()
Returns the Color used to flash drawing operations.
|
static int |
flashCount()
Returns the number of times that drawing operations will flash.
|
static int |
flashTime()
Returns the time delay of drawing operation flashing.
|
Shape |
getClip()
Overrides
Graphics.getClip . |
Rectangle |
getClipBounds()
Overrides
Graphics.getClipBounds . |
Color |
getColor()
Returns the Color used for text drawing operations.
|
int |
getDebugOptions()
Returns the current debugging options for this DebugGraphics.
|
Font |
getFont()
Returns the Font used for text drawing operations.
|
FontMetrics |
getFontMetrics()
Overrides
Graphics.getFontMetrics . |
FontMetrics |
getFontMetrics(Font f)
Overrides
Graphics.getFontMetrics . |
boolean |
isDrawingBuffer()
Returns the drawingBuffer value.
|
static PrintStream |
logStream()
Returns the stream to which the DebugGraphics logs drawing operations.
|
void |
setClip(int x,
int y,
int width,
int height)
Overrides
Graphics.setClip . |
void |
setClip(Shape clip)
Overrides
Graphics.setClip . |
void |
setColor(Color aColor)
Sets the color to be used for drawing and filling lines and shapes.
|
void |
setDebugOptions(int options)
Enables/disables diagnostic information about every graphics
operation.
|
static void |
setFlashColor(Color flashColor)
Sets the Color used to flash drawing operations.
|
static void |
setFlashCount(int flashCount)
Sets the number of times that drawing operations will flash.
|
static void |
setFlashTime(int flashTime)
Sets the time delay of drawing operation flashing.
|
void |
setFont(Font aFont)
Sets the Font used for text drawing operations.
|
static void |
setLogStream(PrintStream stream)
Sets the stream to which the DebugGraphics logs drawing operations.
|
void |
setPaintMode()
Overrides
Graphics.setPaintMode . |
void |
setXORMode(Color aColor)
Overrides
Graphics.setXORMode . |
void |
translate(int x,
int y)
Overrides
Graphics.translate . |
drawPolygon, fillPolygon, finalize, getClipBounds, getClipRect, hitClip, toString
public static final int LOG_OPTION
public static final int FLASH_OPTION
public static final int BUFFERED_OPTION
Frame
.public static final int NONE_OPTION
public DebugGraphics()
public DebugGraphics(Graphics graphics, JComponent component)
graphics
- the Graphics context to slow downcomponent
- the JComponent to draw slowlypublic DebugGraphics(Graphics graphics)
graphics
- the Graphics context to slow downpublic Graphics create()
Graphics.create
to return a DebugGraphics object.public Graphics create(int x, int y, int width, int height)
Graphics.create
to return a DebugGraphics object.create
in class Graphics
x
- the x coordinate.y
- the y coordinate.width
- the width of the clipping rectangle.height
- the height of the clipping rectangle.Graphics.translate(int, int)
,
Graphics.clipRect(int, int, int, int)
public static void setFlashColor(Color flashColor)
public static Color flashColor()
setFlashColor(java.awt.Color)
public static void setFlashTime(int flashTime)
public static int flashTime()
setFlashTime(int)
public static void setFlashCount(int flashCount)
public static int flashCount()
setFlashCount(int)
public static void setLogStream(PrintStream stream)
public static PrintStream logStream()
setLogStream(java.io.PrintStream)
public void setFont(Font aFont)
setFont
in class Graphics
aFont
- the font.Graphics.getFont()
,
Graphics.drawString(java.lang.String, int, int)
,
Graphics.drawBytes(byte[], int, int, int, int)
,
Graphics.drawChars(char[], int, int, int, int)
public Font getFont()
getFont
in class Graphics
setFont(java.awt.Font)
public void setColor(Color aColor)
setColor
in class Graphics
aColor
- the new rendering color.Color
,
Graphics.getColor()
public Color getColor()
getColor
in class Graphics
setColor(java.awt.Color)
public FontMetrics getFontMetrics()
Graphics.getFontMetrics
.getFontMetrics
in class Graphics
Graphics.getFont()
,
FontMetrics
,
Graphics.getFontMetrics(Font)
public FontMetrics getFontMetrics(Font f)
Graphics.getFontMetrics
.getFontMetrics
in class Graphics
f
- the specified fontGraphics.getFont()
,
FontMetrics
,
Graphics.getFontMetrics()
public void translate(int x, int y)
Graphics.translate
.public void setPaintMode()
Graphics.setPaintMode
.setPaintMode
in class Graphics
public void setXORMode(Color aColor)
Graphics.setXORMode
.setXORMode
in class Graphics
aColor
- the XOR alternation colorpublic Rectangle getClipBounds()
Graphics.getClipBounds
.getClipBounds
in class Graphics
null
if no clip is set.Graphics.getClip()
,
Graphics.clipRect(int, int, int, int)
,
Graphics.setClip(int, int, int, int)
,
Graphics.setClip(Shape)
public void clipRect(int x, int y, int width, int height)
Graphics.clipRect
.clipRect
in class Graphics
x
- the x coordinate of the rectangle to intersect the clip withy
- the y coordinate of the rectangle to intersect the clip withwidth
- the width of the rectangle to intersect the clip withheight
- the height of the rectangle to intersect the clip withGraphics.setClip(int, int, int, int)
,
Graphics.setClip(Shape)
public void setClip(int x, int y, int width, int height)
Graphics.setClip
.setClip
in class Graphics
x
- the x coordinate of the new clip rectangle.y
- the y coordinate of the new clip rectangle.width
- the width of the new clip rectangle.height
- the height of the new clip rectangle.Graphics.clipRect(int, int, int, int)
,
Graphics.setClip(Shape)
,
Graphics.getClip()
public Shape getClip()
Graphics.getClip
.getClip
in class Graphics
Shape
object representing the
current clipping area, or null
if
no clip is set.Graphics.getClipBounds()
,
Graphics.clipRect(int, int, int, int)
,
Graphics.setClip(int, int, int, int)
,
Graphics.setClip(Shape)
public void setClip(Shape clip)
Graphics.setClip
.setClip
in class Graphics
clip
- the Shape
to use to set the clipGraphics.getClip()
,
Graphics.clipRect(int, int, int, int)
,
Graphics.setClip(int, int, int, int)
public void drawRect(int x, int y, int width, int height)
Graphics.drawRect
.drawRect
in class Graphics
x
- the x coordinate
of the rectangle to be drawn.y
- the y coordinate
of the rectangle to be drawn.width
- the width of the rectangle to be drawn.height
- the height of the rectangle to be drawn.Graphics.fillRect(int, int, int, int)
,
Graphics.clearRect(int, int, int, int)
public void fillRect(int x, int y, int width, int height)
Graphics.fillRect
.fillRect
in class Graphics
x
- the x coordinate
of the rectangle to be filled.y
- the y coordinate
of the rectangle to be filled.width
- the width of the rectangle to be filled.height
- the height of the rectangle to be filled.Graphics.clearRect(int, int, int, int)
,
Graphics.drawRect(int, int, int, int)
public void clearRect(int x, int y, int width, int height)
Graphics.clearRect
.clearRect
in class Graphics
x
- the x coordinate of the rectangle to clear.y
- the y coordinate of the rectangle to clear.width
- the width of the rectangle to clear.height
- the height of the rectangle to clear.Graphics.fillRect(int, int, int, int)
,
Graphics.drawRect(int, int, int, int)
,
Graphics.setColor(java.awt.Color)
,
Graphics.setPaintMode()
,
Graphics.setXORMode(java.awt.Color)
public void drawRoundRect(int x, int y, int width, int height, int arcWidth, int arcHeight)
Graphics.drawRoundRect
.drawRoundRect
in class Graphics
x
- the x coordinate of the rectangle to be drawn.y
- the y coordinate of the rectangle to be drawn.width
- the width of the rectangle to be drawn.height
- the height of the rectangle to be drawn.arcWidth
- the horizontal diameter of the arc
at the four corners.arcHeight
- the vertical diameter of the arc
at the four corners.Graphics.fillRoundRect(int, int, int, int, int, int)
public void fillRoundRect(int x, int y, int width, int height, int arcWidth, int arcHeight)
Graphics.fillRoundRect
.fillRoundRect
in class Graphics
x
- the x coordinate of the rectangle to be filled.y
- the y coordinate of the rectangle to be filled.width
- the width of the rectangle to be filled.height
- the height of the rectangle to be filled.arcWidth
- the horizontal diameter
of the arc at the four corners.arcHeight
- the vertical diameter
of the arc at the four corners.Graphics.drawRoundRect(int, int, int, int, int, int)
public void drawLine(int x1, int y1, int x2, int y2)
Graphics.drawLine
.public void draw3DRect(int x, int y, int width, int height, boolean raised)
Graphics.draw3DRect
.draw3DRect
in class Graphics
x
- the x coordinate of the rectangle to be drawn.y
- the y coordinate of the rectangle to be drawn.width
- the width of the rectangle to be drawn.height
- the height of the rectangle to be drawn.raised
- a boolean that determines whether the rectangle
appears to be raised above the surface
or sunk into the surface.Graphics.fill3DRect(int, int, int, int, boolean)
public void fill3DRect(int x, int y, int width, int height, boolean raised)
Graphics.fill3DRect
.fill3DRect
in class Graphics
x
- the x coordinate of the rectangle to be filled.y
- the y coordinate of the rectangle to be filled.width
- the width of the rectangle to be filled.height
- the height of the rectangle to be filled.raised
- a boolean value that determines whether the
rectangle appears to be raised above the surface
or etched into the surface.Graphics.draw3DRect(int, int, int, int, boolean)
public void drawOval(int x, int y, int width, int height)
Graphics.drawOval
.drawOval
in class Graphics
x
- the x coordinate of the upper left
corner of the oval to be drawn.y
- the y coordinate of the upper left
corner of the oval to be drawn.width
- the width of the oval to be drawn.height
- the height of the oval to be drawn.Graphics.fillOval(int, int, int, int)
public void fillOval(int x, int y, int width, int height)
Graphics.fillOval
.fillOval
in class Graphics
x
- the x coordinate of the upper left corner
of the oval to be filled.y
- the y coordinate of the upper left corner
of the oval to be filled.width
- the width of the oval to be filled.height
- the height of the oval to be filled.Graphics.drawOval(int, int, int, int)
public void drawArc(int x, int y, int width, int height, int startAngle, int arcAngle)
Graphics.drawArc
.drawArc
in class Graphics
x
- the x coordinate of the
upper-left corner of the arc to be drawn.y
- the y coordinate of the
upper-left corner of the arc to be drawn.width
- the width of the arc to be drawn.height
- the height of the arc to be drawn.startAngle
- the beginning angle.arcAngle
- the angular extent of the arc,
relative to the start angle.Graphics.fillArc(int, int, int, int, int, int)
public void fillArc(int x, int y, int width, int height, int startAngle, int arcAngle)
Graphics.fillArc
.fillArc
in class Graphics
x
- the x coordinate of the
upper-left corner of the arc to be filled.y
- the y coordinate of the
upper-left corner of the arc to be filled.width
- the width of the arc to be filled.height
- the height of the arc to be filled.startAngle
- the beginning angle.arcAngle
- the angular extent of the arc,
relative to the start angle.Graphics.drawArc(int, int, int, int, int, int)
public void drawPolyline(int[] xPoints, int[] yPoints, int nPoints)
Graphics.drawPolyline
.drawPolyline
in class Graphics
xPoints
- an array of x pointsyPoints
- an array of y pointsnPoints
- the total number of pointsGraphics.drawPolygon(int[], int[], int)
public void drawPolygon(int[] xPoints, int[] yPoints, int nPoints)
Graphics.drawPolygon
.drawPolygon
in class Graphics
xPoints
- a an array of x
coordinates.yPoints
- a an array of y
coordinates.nPoints
- a the total number of points.Graphics.fillPolygon(int[], int[], int)
,
Graphics.drawPolyline(int[], int[], int)
public void fillPolygon(int[] xPoints, int[] yPoints, int nPoints)
Graphics.fillPolygon
.fillPolygon
in class Graphics
xPoints
- a an array of x
coordinates.yPoints
- a an array of y
coordinates.nPoints
- a the total number of points.Graphics.drawPolygon(int[], int[], int)
public void drawString(String aString, int x, int y)
Graphics.drawString
.drawString
in class Graphics
aString
- the string to be drawn.x
- the x coordinate.y
- the y coordinate.Graphics.drawBytes(byte[], int, int, int, int)
,
Graphics.drawChars(char[], int, int, int, int)
public void drawString(AttributedCharacterIterator iterator, int x, int y)
Graphics.drawString
.drawString
in class Graphics
iterator
- the iterator whose text is to be drawnx
- the x coordinate.y
- the y coordinate.Graphics.drawBytes(byte[], int, int, int, int)
,
Graphics.drawChars(char[], int, int, int, int)
public void drawBytes(byte[] data, int offset, int length, int x, int y)
Graphics.drawBytes
.drawBytes
in class Graphics
data
- the data to be drawnoffset
- the start offset in the datalength
- the number of bytes that are drawnx
- the x coordinate of the baseline of the texty
- the y coordinate of the baseline of the textGraphics.drawChars(char[], int, int, int, int)
,
Graphics.drawString(java.lang.String, int, int)
public void drawChars(char[] data, int offset, int length, int x, int y)
Graphics.drawChars
.drawChars
in class Graphics
data
- the array of characters to be drawnoffset
- the start offset in the datalength
- the number of characters to be drawnx
- the x coordinate of the baseline of the texty
- the y coordinate of the baseline of the textGraphics.drawBytes(byte[], int, int, int, int)
,
Graphics.drawString(java.lang.String, int, int)
public boolean drawImage(Image img, int x, int y, ImageObserver observer)
Graphics.drawImage
.drawImage
in class Graphics
img
- the specified image to be drawn. This method does
nothing if img
is null.x
- the x coordinate.y
- the y coordinate.observer
- object to be notified as more of
the image is converted.false
if the image pixels are still changing;
true
otherwise.Image
,
ImageObserver
,
ImageObserver.imageUpdate(java.awt.Image, int, int, int, int, int)
public boolean drawImage(Image img, int x, int y, int width, int height, ImageObserver observer)
Graphics.drawImage
.drawImage
in class Graphics
img
- the specified image to be drawn. This method does
nothing if img
is null.x
- the x coordinate.y
- the y coordinate.width
- the width of the rectangle.height
- the height of the rectangle.observer
- object to be notified as more of
the image is converted.false
if the image pixels are still changing;
true
otherwise.Image
,
ImageObserver
,
ImageObserver.imageUpdate(java.awt.Image, int, int, int, int, int)
public boolean drawImage(Image img, int x, int y, Color bgcolor, ImageObserver observer)
Graphics.drawImage
.drawImage
in class Graphics
img
- the specified image to be drawn. This method does
nothing if img
is null.x
- the x coordinate.y
- the y coordinate.bgcolor
- the background color to paint under the
non-opaque portions of the image.observer
- object to be notified as more of
the image is converted.false
if the image pixels are still changing;
true
otherwise.Image
,
ImageObserver
,
ImageObserver.imageUpdate(java.awt.Image, int, int, int, int, int)
public boolean drawImage(Image img, int x, int y, int width, int height, Color bgcolor, ImageObserver observer)
Graphics.drawImage
.drawImage
in class Graphics
img
- the specified image to be drawn. This method does
nothing if img
is null.x
- the x coordinate.y
- the y coordinate.width
- the width of the rectangle.height
- the height of the rectangle.bgcolor
- the background color to paint under the
non-opaque portions of the image.observer
- object to be notified as more of
the image is converted.false
if the image pixels are still changing;
true
otherwise.Image
,
ImageObserver
,
ImageObserver.imageUpdate(java.awt.Image, int, int, int, int, int)
public boolean drawImage(Image img, int dx1, int dy1, int dx2, int dy2, int sx1, int sy1, int sx2, int sy2, ImageObserver observer)
Graphics.drawImage
.drawImage
in class Graphics
img
- the specified image to be drawn. This method does
nothing if img
is null.dx1
- the x coordinate of the first corner of the
destination rectangle.dy1
- the y coordinate of the first corner of the
destination rectangle.dx2
- the x coordinate of the second corner of the
destination rectangle.dy2
- the y coordinate of the second corner of the
destination rectangle.sx1
- the x coordinate of the first corner of the
source rectangle.sy1
- the y coordinate of the first corner of the
source rectangle.sx2
- the x coordinate of the second corner of the
source rectangle.sy2
- the y coordinate of the second corner of the
source rectangle.observer
- object to be notified as more of the image is
scaled and converted.false
if the image pixels are still changing;
true
otherwise.Image
,
ImageObserver
,
ImageObserver.imageUpdate(java.awt.Image, int, int, int, int, int)
public boolean drawImage(Image img, int dx1, int dy1, int dx2, int dy2, int sx1, int sy1, int sx2, int sy2, Color bgcolor, ImageObserver observer)
Graphics.drawImage
.drawImage
in class Graphics
img
- the specified image to be drawn. This method does
nothing if img
is null.dx1
- the x coordinate of the first corner of the
destination rectangle.dy1
- the y coordinate of the first corner of the
destination rectangle.dx2
- the x coordinate of the second corner of the
destination rectangle.dy2
- the y coordinate of the second corner of the
destination rectangle.sx1
- the x coordinate of the first corner of the
source rectangle.sy1
- the y coordinate of the first corner of the
source rectangle.sx2
- the x coordinate of the second corner of the
source rectangle.sy2
- the y coordinate of the second corner of the
source rectangle.bgcolor
- the background color to paint under the
non-opaque portions of the image.observer
- object to be notified as more of the image is
scaled and converted.false
if the image pixels are still changing;
true
otherwise.Image
,
ImageObserver
,
ImageObserver.imageUpdate(java.awt.Image, int, int, int, int, int)
public void copyArea(int x, int y, int width, int height, int destX, int destY)
Graphics.copyArea
.copyArea
in class Graphics
x
- the x coordinate of the source rectangle.y
- the y coordinate of the source rectangle.width
- the width of the source rectangle.height
- the height of the source rectangle.destX
- the horizontal distance to copy the pixels.destY
- the vertical distance to copy the pixels.public void dispose()
Graphics.dispose
.dispose
in class Graphics
Graphics.finalize()
,
Component.paint(java.awt.Graphics)
,
Component.update(java.awt.Graphics)
,
Component.getGraphics()
,
Graphics.create()
public boolean isDrawingBuffer()
public void setDebugOptions(int options)
public int getDebugOptions()
setDebugOptions(int)
Submit a bug or feature
For further API reference and developer documentation, see Java SE Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.
Copyright © 1993, 2015, Oracle and/or its affiliates. All rights reserved.


A demonstration of the jQuery Nearest Element plugin. Check out the code behind it.
Select an edge/corner to find the nearest blocks (with example code). Drag the corners to resize the container.


Before Change
def fbase(fname):
Strip directory and all extensions from a filename.
return os.path.basename(fname).split(".", 1)[0]
def rbase(fname):
Strip directory and final extension from a filename.
After Change
def fbase(fname):
Strip directory and all extensions from a filename.
base = os.path.basename(fname)
// Gzip extension usually follows another extension
if base.endswith(".gz"):
base = base[:-3]
// Cases to drop more than just the last dot
known_multipart_exts = (
".antitargetcoverage.cnn", ".targetcoverage.cnn",
// Pipeline suffixes
".recal.bam", ".deduplicated.realign.bam",
)
for ext in known_multipart_exts:
if base.endswith(ext):
base = base[:-len(ext)]
break
else:
base = base.rsplit(".", 1)[0]
return base


JavaScript is disabled on your browser.
Skip navigation links
Overview
Package
Class
Use
Tree
Deprecated
Index
Help
Prev Letter
Next Letter
Frames
No Frames
All Classes
A
B
C
D
E
F
G
H
I
L
M
N
O
P
Q
R
S
T
U
V
W
X
Y
L
lastNode
- Variable in class dsl.
Play
The last node explored.
lastNodeStack
- Variable in class dsl.
Play
The standard, normal search stack.
leaveForLater(Node, Outcome, Map<String, Tip>)
- Method in class dsl.
Play
Inscribes a node to be visited later in the search with a different outcome than the one passed to
Play.onSearch(Object, Supplier, SendException, ReceiveException)
.
lengthen(String)
- Method in class communications.
ShortMessage
Returns a
FullMessage
object with the same information as the current message with "from" field given by the user.
listener
- Variable in class communications.util.
QueueResource
The thread that listens to incoming messages.
listenMessages()
- Method in class communications.util.
QueueResource
listIndex
- Variable in class dsl.
Play
listToBitSet(List<Short>)
- Static method in class dsl.
FlowchartUtils
listToShortArray(List<Short>)
- Static method in class dsl.
FlowchartUtils
load(Part, CommunicationResource<P>)
- Method in class dsl.
Actor
Initializes an yet uninitialized Actor whith an empty address map.
load(Part, CommunicationResource<P>, Map<String, String>)
- Method in class dsl.
Actor
Initializes an yet uninitialized Actor.
localAddress
- Variable in class communications.util.
Dump
A String representation of the this host's address.
logout()
- Method in class protocols.
XMPPWithIQProtocol
LoopFoundException()
- Constructor for exception dsl.
Play.LoopFoundException
A
B
C
D
E
F
G
H
I
L
M
N
O
P
Q
R
S
T
U
V
W
X
Y
Skip navigation links
Overview
Package
Class
Use
Tree
Deprecated
Index
Help
Prev Letter
Next Letter
Frames
No Frames
All Classes


Akan names are derived from Ghanian culture. Frequently in Ghana, children are given their first name as a 'day name' which corresponds to the day in the week they were born. The akan names calculator takes the user's birthday date and calculates the day of the week they were born and then depending on their gender outputs their Akan Name. To calculate your akan name, fill in the form and press submit.
fill in your birth date details here:


Each account is mapped to one or multiple roles. Depending on the role, some menu items are enabled/disabled.
Here are a few sample accounts you can use to start playing:
| Role | Username | Password |
| Administrator | admin | admin123 |
| Project Manager | john | john123 |
| Developer | kate | kate123 |


Dragnet Radio Drama
Select an episode to listen to.
These audio programs are from the Internet Archive. Press Stop to unload the episode to start a new one.
These audio programs are from the Internet Archive. Press Stop to unload the episode to start a new one.


ERROR.SYS file (\FBB) This file gives a description of the error in the BBS, as it occurs. This file has a free format, using text. The contents are error reports from the software, mostly with the TNC interface.
This page was last updated


Add a Restaurant
arrow_back
ADD A RESTAURANT
Please fill in the details to sign up.
Enter the name of restaurant
Enter the username
Enter the password
Enter the location of your restaurant
Choose your option
South Indian
North Indian
Pure Veg
Mexican
Italian
Chinese
Select type of restaurant
Enter the number of tables available for booking
restore
Select opening time
restore
Select closing time
Choose a profile picture
Sign Up


| this.getPageNumber(): number | ||
|---|---|---|
| Return number of pages in pdf | ||
| Return | ||
| number | The number of page |
| this.rotate(angle: number): void | ||
|---|---|---|
| Rotate all pages managed by implementation | ||
| Argument | Default value | Description |
| angle: number | The angle in degree to rotate |
| this.reload(): PDFPromise<number> | ||
|---|---|---|
| Reload the pdf managed by the implementation | ||
| Return | ||
| PDFPromise<number> | Promise of number of pages loaded |
| this.previousIsSelectable(): boolean | ||
|---|---|---|
| Return if there is a previous item of current selected | ||
| Return | ||
| boolean | Exist an item before the current selected |
| this.nextIsSelectable(): boolean | ||
|---|---|---|
| Return if there is a next item of current selected | ||
| Return | ||
| boolean | Exist an item after the current selected |
| this.selectFirst(): number | ||
|---|---|---|
| Select the first item. | ||
| Return | ||
| number | The previous item number selected or NaN |
| this.selectPrevious(): number | ||
|---|---|---|
| Select the previous item. | ||
| Return | ||
| number | The previous item number selected or NaN |
| this.selectNext(): number | ||
|---|---|---|
| Select the next item. | ||
| Return | ||
| number | The previous item number selected or NaN |
| this.selectLast(): number | ||
|---|---|---|
| Select the last item. | ||
| Return | ||
| number | The previous item number selected or NaN |
| this.selectItemIndex(index: number): number | ||
|---|---|---|
| Select the item index | ||
| Argument | Default value | Description |
| index: number | The index 0 based | |
| Return | ||
| number | The previous item number selected or NaN |
| this.unselect(): number | ||
|---|---|---|
| Unset the selection. | ||
| Return | ||
| number | The previous item number selected or NaN |
| this.rotateSelected(angle: number): void | ||
|---|---|---|
| Rotate the selected page in pdf managed by implementation | ||
| Argument | Default value | Description |
| angle: number | The angle in degree to rotate |
| this.getSelectedPageIndex(): number | ||
|---|---|---|
| Return the selected page number in implementation, page number is 1 based. | ||
| Return | ||
| number | The number of page |
| this.getSelectedItemIndex(): number | ||
|---|---|---|
| Return the selected item number in implementation, item number is 0 based. | ||
| Return | ||
| number | The number of page |


| Internal ID | Type | nlapiSubmitField | Label | Required | Help |
|---|---|---|---|---|---|
| accountingbook | select | false | Accounting Book | false | |
| amortizationtype | select | false | Type | false | |
| enddate | date | false | End Date | false | |
| externalid | text | false | ExternalId | false | |
| initialamount | rate | false | Initial Amount | false | |
| isinactive | checkbox | false | Inactive | false | |
| job | select | false | Project | false | |
| name | text | false | Name | true | |
| parentSched | select | false | Template | false | |
| periodoffset | integer | false | Period Offset | true | |
| recogintervalsrc | select | false | Term Source | false | |
| recurrencetype | select | false | Method | false | |
| remainingdeferredbalance | currency | false | Remaining Deferred Balance | false | |
| residual | rate | false | Residual | false | |
| revrecoffset | integer | false | Start Offset | true | |
| schedulenumber | text | false | Number | false | |
| sourcetran | select | false | Created From | false | |
| startdate | date | false | Start Date | false | |
| status | select | false | Status | false | |
| totalamortized | currency | false | Total Amortized | false | |
| totalamount | currency2 | false | Amount | false |
| Internal ID | Type | Label | Required |
|---|---|---|---|
| defrevaccount | select | Account | false |
| id | integer | false | |
| incomeaccount | text | false | |
| isrecognized | checkbox | Is Recognized | false |
| jdate | date | Date Executed | false |
| journal | text | Journal | false |
| periodoffset | integer | Period Offset | true |
| postingperiod | text | false | |
| recamount | rate | Amount | true |
| recurdate | date | Date | false |
| Join ID | Join Description | Actual Join Name |
|---|---|---|
| user | User | Employee |
| vendor | Vendor | Vendor |
| Internal ID | Type | Label |
|---|---|---|
| accountingbook | select | Accounting Book |
| amorstatus | select | Status |
| amortizedamount | currency | Total Amortized |
| amortype | select | Type |
| amount | currency | Amount |
| currencyname | select | Schedule Currency |
| deferredamount | currency | Remaining Deferred Balance |
| destacct | select | Destination Account |
| formuladate | date | Formula (Date) |
| formulanumeric | float | Formula (Numeric) |
| formulatext | text | Formula (Text) |
| initialamt | currency | Initial Amount |
| internalid | select | Internal ID |
| internalidnumber | integer | Internal ID (Number) |
| isrecognized | checkbox | Is Recognized? |
| name | text | Schedule Name |
| pctcomplete | float | % Complete |
| pctrecognition | float | % Recog. |
| periodoffset | integer | Period Offset |
| postperiod | select | Posting Period |
| residual | currency | Residual |
| scheddate | date | Date |
| schedulenumber | integer | Number |
| schedulenumbertext | text | Number/ID |
| sourceacct | select | Source Account |
| srctranpostperiod | select | Source Transaction Posting Period |
| srctrantype | select | Transaction Type |
| startoffset | integer | Start Offset |
| templatename | text | Template Name |
| useforeignamounts | checkbox | Use Transaction Currency |
| Internal ID | Type | Label |
|---|---|---|
| accountingbook | select | Accounting Book |
| amorstatus | text | Status |
| amortemplate | select | Template Name |
| amortizedamount | currency | Total Amortized |
| amortype | text | Type |
| amount | currency | Amount (Schedule Total) |
| currency | select | Schedule Currency |
| deferredamount | currency | Remaining Deferred Balance |
| destacct | select | Destination Account |
| formulacurrency | currency | Formula (Currency) |
| formuladate | date | Formula (Date) |
| formuladatetime | datetime | Formula (Date/Time) |
| formulanumeric | float | Formula (Numeric) |
| formulapercent | percent | Formula (Percent) |
| formulatext | text | Formula (Text) |
| initialamt | currency | Initial Amount |
| internalid | select | Internal ID |
| isrecognized | checkbox | Is Recognized? |
| name | text | Schedule Name |
| pctcomplete | percent | % Complete |
| pctrecognition | percent | % Recog. |
| periodoffset | integer | Period Offset |
| recuramount | currency | Amount |
| recurfxamount | currency | Amount (Foreign Currency) |
| residual | currency | Residual |
| scheddate | date | Date |
| schedulenumber | text | Number |
| sourceacct | select | Source Account |
| srctran | select | Source Transaction |
| srctranpostperiod | select | Posting Period |
| startoffset | integer | Start Offset |
| useforeignamounts | checkbox | Use Transaction Currency |


golden glowing text outlined text
Normal text emphasized text secondary text ancillary text What I’m saying is that it’s so, so simple to make sites easier to read.   Click me!
“😀 Blockquote featuring the "fast and good enough" font-family (.o⋄fontꘌfast-and-good-enough)” — Some stranger 🥰
“😀 Blockquote featuring the "system" font-family (.o⋄fontꘌsystem)” — Some stranger 🥰
“😀 Blockquote featuring the nice and precise "roboto" font-family (.o⋄fontꘌroboto)” — Some stranger 🥰
“😀 Blockquote featuring the nice and precise "roboto condensed" font-family (.o⋄fontꘌroboto-condensed)” — Some stranger 🥰
“😀 Blockquote featuring the fun and gamy "Pix Antiqua" font-family (.omr⋄font⁚pixantiqua)” — Some stranger 🥰
“😀 Blockquote featuring the nice and fantasy "Spectral" font-family (.omr⋄font⁚spectral)” — Some stranger 🥰


rotten > Library > Biographies > Crime > Spree Killers > Eric Harris and Dylan Klebold
Eric Harris and Dylan Klebold
Colombine Massacre
"There is nothing that anyone could have done to prevent this. No one is to blame except me and Vodka." Harris.
Killed 13 at Colombine High School, 20 Apr 1999.
"You know what I hate?  You know what I hate? People who mispronounce words, like 'acrost,' and 'pacific' for 'specific,' and 'expresso' instead of 'espresso.' You know what I hate? People who drive slow in the fast lane, God these people do not know how to drive. You know what I hate? The WB network!!!!  - Excerpt from Eric Harris' diary
Scapegoats: The Matrix, Marilyn Manson, guns, violent videogames, their parents.
Timeline
| 9 Apr 1981 |
Eric David Harris born to Wayne Nelson Harris and Katherine Ann Harris. |
| 11 Sep 1981 |
Dylan Bennett Klebold born to Thomas Klebold and Susan Klebold. |
| 25 Mar 1998 |
Eric Harris fills out a self-evaluation form regarding his mental health, in which he describes having homicidal thoughts, mood swings, anger, anxiety, depression, and loneliness. Again, this is a self-evaluation that is turned over to his therapist. |
| 17 Jan 1999 |
Eric Harris writes a short story for his class, in which he describes a game of "Doom" from the first person perspective, including gathering up bullets and weapons, and witnessing piles of bodies. He gets a C+. Teacher's comments: "Yours is a unique approach and your writing works in a gruesome way - good details and mood setting". |
| 25 Mar 1999 |
The entire Klebold family (Dylan, brother Byron, parents) drives to the University of Arizona to pick out Dylan's dorm room. |
| 15 Apr 1999 |
Eric Harris' application to join the marines is rejected due to temperament and his prescription for the anger management drug Luvox. |
| 19 Apr 1999 |
Entry in Dylan Klebold's school notebook, excerpt: "About 26.5 hours from now the judgement will begin. Difficult but not impossible, necessary, nervewracking and fun. What fun is life without a little death?  Everything has a touch of triviality to it." Last entry: "Walk in, set bombs at 11:09, for 11:17. Leave, set car bombs. Drive to Clemete Park. Gear up. Get back by 11:15. Park cars. set car bombs for 11:18. get out, go to outside hill, wait. When first bombs go off, attack. have fun!" |
| 20 Apr 1999 |
Zero Hour. After their homemade timebombs fail to detonate in the school cafeteria, the heavily-armed duo of Eric Harris and Dylan Klebold decide to prowl through Columbine High School, indiscriminately gunning down classmates. A total of 15 are killed in their shooting spree: 12 students dead, 1 teacher, Harris dead from self-inflicted sawed-off shotgun in mouth, Klebold from bullet to left temple via TEC-9. Contrary to news reports, their selection of victims is apparently random; they aren't hunting for jocks or blacks. Nor do they execute that Christian girl -- Valeen Schnurr in fact manages to crawl away and live to tell her story. They are not goths, they aren't gay, nor were they ever members of that dorky clique calling themselves the "Trenchcoat Mafia." They don't even listen to Marilyn Manson. Harris and Klebold are just a couple of extremely pissed-off kids with an arsenal. |
| 30 Apr 1999 |
Brian Rohrbough, father of slain student Daniel Rohrbough, chops down two of the 15 wooden crucifixes erected in Clement Park. "I don't think any thinking person in this country is going to disagree with me... We never, ever honor a murderer in the same place as the memorial for his victims." |
| 18 Aug 1999 |
Three swastikas are found etched on the inside and outside of Columbine High School, during the week of the "Take Back Our School" rally. Each are about an inch in diameter. One is etched into a brick retaining wall and two are etched inside a girls' bathroom. |
| 26 Dec 2001 |
Brian Rohrbough, father of slain student Daniel Rohrbough, files suit against the Jefferson County Sheriff and several deputies for allegedly killing his son. "He was running from the gunmen when he was shot and killed. I do not believe he was caught in a crossfire. I believe he was aimed at by an officer who suspected him as being a gunman." |
| 24 May 2001 |
Brian Rohrbough, father of slain student Daniel Rohrbough: "This bullet positively didn't come from Klebold... We are outraged to find that the sheriff's department would lie to us and the public about physical evidence. My son clearly was an innocent victim... I think it was a law enforcement officer, but I'm not prepared at this point in time, without knowing absolutely who, to even speculate on something like that." |
| 26 Dec 2001 |
Brian Rohrbough, father of slain student Daniel Rohrbough, files a wrongful death suit against Denver SWAT team member Sgt. Dan O'Shea. |
| 22 Apr 2002 |
Brian Rohrbough, father of slain student Daniel Rohrbough, issues a public apology to Sgt. Dan O'Shea for claiming that the officer had killed his son. "We're sorry for the pain and frustration we have caused him." |
| 28 Oct 2003 |
Brian Rohrbough, father of slain student Daniel Rohrbough, files suit against former Arapahoe County Deputy James Taylor for claiming that a Denver SWAT team member had killed Daniel. |
Pornopolis |
Rotten |
Faces of Death |
Famous Nudes
|


Home
Projects
Blog
About
Blog Posts
Reflecting on the Website
-January 10, 2015
Asking Good Questions
-January 9, 2015
Conflict
-January 2, 2015
How the Internet Works
-January 1, 2015
Affirmation and Sterotype Threat
-December 11, 2014
Ruby Hashes Versus JavaScript Objects
-December 11, 2014
Stereotype Threat
-December 6, 2014
Class Methods in Ruby
-December 6, 2014
Pair Programming and Feedback
-November 28, 2014
Seeing with Ruby Classes
-November 26, 2014
Computing in a Changing Climate
-November 21, 2014
Enumerable#group_by
-November 20, 2014
Reflecting on My Thinking Style and Learning
-November 13, 2014
Arrays and Hashes in Ruby
-November 12, 2014
The Difference Between Margin, Padding, and Border
-November 7, 2014
Shereef's Fireside Chat
-October 31, 2014
Git and GitHub: An Introduction
-October 31, 2014


| Package | Description |
|---|---|
| org.datavec.image.transform |
| Modifier and Type | Class and Description |
|---|---|
class |
BoxImageTransform
Boxes images to a given width and height without changing their aspect ratios,
or the size of the objects, by either padding or cropping them from the center.
|
class |
ColorConversionTransform
Color conversion transform using CVT (cvtcolor):
CVT Color.
|
class |
CropImageTransform
Crops images deterministically or randomly.
|
class |
EqualizeHistTransform
"Histogram Equalization equalizes the intensity distribution of an image or flattens the intensity distribution curve.
|
class |
FilterImageTransform
Filters images using FFmpeg (libavfilter):
FFmpeg Filters Documentation.
|
class |
FlipImageTransform
Flips images deterministically or randomly.
|
class |
LargestBlobCropTransform
crop images based on it's largest blob.
|
class |
MultiImageTransform
Transforms images deterministically or randomly with the help of an array of ImageTransform
|
class |
PipelineImageTransform
Allows creation of image transform pipelines, either sequentially or randomly.
|
class |
RandomCropTransform
Randomly crops an image to a desired output size.
|
class |
ResizeImageTransform
ResizeImageTransform is suited to force the same image size for whole pipeline
and it doesn't use any random factor for width and height.
|
class |
RotateImageTransform
Rotates and scales images deterministically or randomly.
|
class |
ScaleImageTransform
ScaleImageTransform is aim to scale by a certain random factor,
not the final size of the image.
|
class |
ShowImageTransform
Shows images on the screen, does not actually transform them.
|
class |
WarpImageTransform
Warps the perspective of images deterministically or randomly.
|
Copyright © 2020. All rights reserved.


Popular modern day languages have progressed from predominatly procedural/imperative to single dispatch object oriented. Most mainstream languages also incorporate functional and generic programming to a limited extent as well. We will worry only about the most common subset of features for this article.
The most common methods of dealing with multiple dispatch using these features will be shown. Keep in mind that these have been discovered through my own research and experience, so read through this with a critical mind, and be sure to diversify your sources on this topic. Also, please note that the criticism sections following each approach will be loaded with the author's opinion, not actual facts.
This entry will utilize two languages with which most programmers will have at least a passing familiarity: C and Java.
As a final note, it is important to understand that each of these techniques are fundamentally different. While in many cases they are interchangable, there are instances where they are not. For example, table based solutions allow the branching logic to be modified at runtime, while switch and object based solutions do not inherently support this.
What is Multiple Dispatch?
Code is often written against abstractions. These abstractions are helpful in the development process, but they all must eventually be resolved to a concrete type in order to do actual work.
A Single Dispatch Example
As a quick example from an object oriented language, an Animal
abstraction may provide a speak
method. A programmer may write:
animal.speak();
This line of code has no real meaning, though. If an Animal is a purely abstract object, then its speak
method will have no actual code. At runtime, the program will dynamically dispatch to object's underlying type and call that object's speak
method. In other words, if the abstract animal
object points to an instance of Dog
class, then the above call may print woof
to the screen. The above call might effectively be translated to
dog.speak(); // prints "woof"
In this case, the actual code called is determined by the underlying type of one abstraction. One abstraction leads to a single dispatch. The mechanism by which this (usually?) happens will be discussed in the procedural/imperative section.
A Multiple Dispatch Example
At times it my be necessary to dispatch based on multiple types.
A programmer writing a game of rock-paper-scissors might use an abstraction of Attacker
to represent a potential move. When the actual game is played the type of both attackers will need to be known. What we want to write is something along the lines of:
(attacker1 and attacker2).determineWinner();
As an example, attacker1 might be resolved to Rock
and attacker2 might be resolved to Scissors
. In this case, the code relating to rock beating scissors would be called.
Multiple Dispatch in C
There are two main ways to go about this in C. Both of these involve defining types which explicitly describe themselves. In other words, an enum may be defined as:
enum { ROCK, PAPER, SCISSORS} attacker;
The types for each attack could be defined by:
struct { attacker TYPE = ROCK; }
struct { attacker TYPE = PAPER; }
struct { attacker TYPE = SCISSORS; }
Big Switch Statement
The typically cringeworthy solution is to have a Big Switch Statement to handle every possible combination. In psuedocode, for sanity related reasons:
switch attacker1.TYPE:
case ROCK:
switch attacker2.TYPE:
case ROCK: tie
case PAPER: lose
case SCISSORS: win
case PAPER:
switch attacker2.TYPE:
case ROCK: win
etc...
etc...
This switch statement ends up being huge, even with only three types.
Beyond factoring each switch and/or case statement into its own function, the switch statement itself may be replaced with a jump table.
Criticisms
Good * Not too difficult to manually trace through
Bad Adding/removing types requires a lot of work which won't be verified by a compiler Have to add a type field to all types and keep up with these * These switch statements tend to poliferate
The first bullet under the negative criticisms is particularly important. Adding or removing types involves modifying a lot of code spread out all over your program, and the compiler will not let you know if you have left anything out in many cases.
Big Jump Table
The logic of a switch statement or chain of if/else statements based on explicitly defined types may be replaced by a jump table. Before diving into the code, imagine a matrix of possible outcomes for the game itself:
| - | Rock | Paper | Scissors |
|---|---|---|---|
| Rock | Tie | Lose | Win |
| Paper | Win | Tie | Lose |
| Scissors | Lose | Win | Tie |
We can translate this into code by creating functions for every possible combination of rock-paper-scissors, then populating a table based on the intersection of the types. Dispatching to the correct function can then be done by looking up the function pointer in the table:
BattleFunction generate_outcome = gameMatrix[attacker1.TYPE, attacker2.TYPE];
generate_outcome();
Maintaining the TYPE
field in all of our objects is still a bit of a pain. If we were to add or remove any types, we would have to edit our enum and update our matrix.
Criticisms
Good Tables can be constructed outside of static code. This consolidation makes modification easier and will usually not even require modification of the code itself. Leads to simpler code. Functions which would typically contain large switch statements simply index into a table.
Bad Much more difficult to debug/trace. Still requires types to label themselves.
Introspection
While finding a language or environment in which introspection is unavailable is not unheard of, reflection is commonly used to help alleviate some of the issues with the C-based approaches to this problem.
Instead of manually tracking each type, the underlying type of each abstraction is determined via a language's introspection features, and then the relevant code is dispatched to based on the findings.
As a side note, this approach is often times discovered independently and immediatelly touted as a panacea for the ugly switch/table based methods previously described, and the also ugly double indirection used in object oriented languages. It is my opinion that it is not. While it does simplify some aspects of the table-based approach, it still carries many of the drawbacks associated with that method, and it introduces many of its own drawbacks in the process. These will be detailed in the general compare/contrast of each method toward the end.
Criticisms
Good * Removes the need for types to keep track of themselves.
Bad Makes debugging/tracing even more painful. While explicit tracking of types is removed, the developer must still be mentally aware of what these types are when updating tables.
Object Oriented Approach
In object oriented languages, polymorphism is the go-to mechanism for replacing branches based on type. To implement double dispatch, then, one can first write something along the lines of:
attacker1.handle(attacker2);
This dispatches to the appropriate handle
method based on attacker1's type. If attacker1
is a rock
, for example, you could mentally translate this to:
rock.handle(attacker2);
Once we're in the Rock's handle
method, we know we are a rock. Now all that's left to do is figure out what attacker2 is. We can do this in similar fasion inside of the rock.handle method:
attacker2.handleRock(this);
We know that we're a rock
, so this
is really rock
. Again, if attacker2
is actually paper
, the call may be mentally translated to:
paper.handleRock(rock)
And in our Paper class, the handleRock method can contain the code which handles the rock versus paper interaction.
Criticisms
Good Returns many of the potential errors to compile time Avoids the poliferation inherent in switch-based solutions
Bad Can seem convoluted to the uninitiated It is an object oriented solution which violates many object oriented ideas * Costs associated with adding/removing types vary based on which set of types you are modifying
I will spend the second half of this article examining this object oriented approach, as I find it to be heavily criticized in ways which I think are unfair. If the above bullets are not clear, feel free to read on.
Header 3
This is a blockquote.
This is the second paragraph in the blockquote.
This is an H2 in a blockquote