public abstract class WhiteboardObjectJabberImpl extends java.lang.Object implements WhiteboardObject
WhiteboardObjectJabberImpl are created through the WhiteboardSession session.
All WhiteboardObjectJabberImpl have whiteboard object id.
NAME
Constructor and Description |
---|
WhiteboardObjectJabberImpl()
Default WhiteboardObjectJabberImpl constructor
|
WhiteboardObjectJabberImpl(java.lang.String id,
int thickness,
int color)
WhiteboardObjectJabberImpl constructor
|
Modifier and Type | Method and Description |
---|---|
protected java.lang.String |
colorToHex(java.awt.Color color)
Converts a color to a hexa color code
|
protected java.lang.String |
colorToHex(int color)
Converts a int color to a hexa color code
|
boolean |
equals(java.lang.Object obj)
Indicates whether some other WhiteboardObject is "equal to" this one.
|
protected java.lang.String |
generateID()
Generate a String uniquely identifying this WhiteboardObject.
|
int |
getColor()
Returns an integer representing the color of this object.
|
java.lang.String |
getID()
Returns a String uniquely identifying this WhiteboardObject.
|
int |
getThickness()
Returns an integer indicating the thickness (represented as number of
pixels) of this whiteboard object (or its border).
|
void |
setColor(int color)
Sets the color of this whiteboard object (or rather it's border).
|
protected void |
setID(java.lang.String ID)
Sets a String uniquely identifying this WhiteboardObject.
|
void |
setThickness(int thickness)
Sets the thickness (in pixels) of this whiteboard object.
|
abstract java.lang.String |
toXML()
Returns the XML reppresentation of the PacketExtension.
|
public WhiteboardObjectJabberImpl()
public WhiteboardObjectJabberImpl(java.lang.String id, int thickness, int color)
id
- A String that uniquely identifies this WhiteboardObject.thickness
- An integer indicating the thickness (number of pixels).color
- The RGB value of the color of this object.protected java.lang.String generateID()
public java.lang.String getID()
getID
in interface WhiteboardObject
protected void setID(java.lang.String ID)
ID
- a String that uniquely identifies this WhiteboardObject.public int getThickness()
getThickness
in interface WhiteboardObject
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
obj
- the reference object with which to compare.true
if this object is the same as the obj
argument; false
otherwise.public int getColor()
getColor
in interface WhiteboardObject
public void setColor(int color)
setColor
in interface WhiteboardObject
color
- the color that we'd like to set on this object (using
standard RGB encoding).protected java.lang.String colorToHex(int color)
color
- colorprotected java.lang.String colorToHex(java.awt.Color color)
color
- colorpublic void setThickness(int thickness)
setThickness
in interface WhiteboardObject
thickness
- the number of pixels that this object (or its border)
should be thick.public abstract java.lang.String toXML()
Jitsi, the OpenSource Java VoIP and Instant Messaging client.
Distributable under Apache license.