|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectigeo.IObject
igeo.IGeometry
igeo.ICurve
igeo.ITensionLine
public class ITensionLine
Class of IDynamicObject to simulate tension force between two particles.
Field Summary | |
---|---|
java.util.ArrayList<IObject> |
targets
target objects to be updated by dynamic object |
ITension |
tensionDynamics
|
Fields inherited from class igeo.ICurve |
---|
curve |
Fields inherited from class igeo.IObject |
---|
attribute, dynamics, graphics, parameter, server, userData |
Fields inherited from interface igeo.ITensionI |
---|
defaultTension |
Constructor Summary | |
---|---|
ITensionLine(IParticleI p1,
IParticleI p2)
|
|
ITensionLine(IParticleI p1,
IParticleI p2,
double tension)
|
|
ITensionLine(IVecI p1,
IVecI p2)
|
|
ITensionLine(IVecI p1,
IVecI p2,
double tension)
|
Method Summary | |
---|---|
ITensionLine |
attr(IAttribute at)
set attributes |
ITensionLine |
clr(java.awt.Color c)
|
ITensionLine |
clr(java.awt.Color c,
double alpha)
|
ITensionLine |
clr(java.awt.Color c,
float alpha)
|
ITensionLine |
clr(java.awt.Color c,
int alpha)
|
ITensionLine |
clr(double dgray)
|
ITensionLine |
clr(double dgray,
double dalpha)
|
ITensionLine |
clr(double dr,
double dg,
double db)
|
ITensionLine |
clr(double dr,
double dg,
double db,
double da)
|
ITensionLine |
clr(float fgray)
|
ITensionLine |
clr(float fgray,
float falpha)
|
ITensionLine |
clr(float fr,
float fg,
float fb)
|
ITensionLine |
clr(float fr,
float fg,
float fb,
float fa)
|
ITensionLine |
clr(IColor c)
to set an object color |
ITensionLine |
clr(IColor c,
double alpha)
to set color, with alpha value overwritten |
ITensionLine |
clr(IColor c,
float alpha)
to set color, with alpha value overwritten |
ITensionLine |
clr(IColor c,
int alpha)
to set color, with alpha value overwritten |
ITensionLine |
clr(int gray)
|
ITensionLine |
clr(int gray,
int alpha)
|
ITensionLine |
clr(int r,
int g,
int b)
|
ITensionLine |
clr(int r,
int g,
int b,
int a)
|
ITensionLine |
clr(IObject o)
to set the same color with the object |
boolean |
constant()
if constantTension is true, amount of force is always constant and it's equals to tension. |
ITensionLine |
constant(boolean cnst)
if constantTension is true, amount of force is always constant and it's equals to tension. |
ITensionLine |
hide()
|
ITensionLine |
hsb(double h,
double s,
double b)
|
ITensionLine |
hsb(double h,
double s,
double b,
double a)
|
ITensionLine |
hsb(float h,
float s,
float b)
|
ITensionLine |
hsb(float h,
float s,
float b,
float a)
|
void |
initTensionLine(IParticleI p1,
IParticleI p2)
|
void |
initTensionLine(IParticleI p1,
IParticleI p2,
double tension)
|
void |
interact(java.util.ArrayList<IDynamics> dynamics)
behavior definition of interaction with other dynamic objects. |
ITensionLine |
layer(ILayer l)
Set layer by ILayer object |
ITensionLine |
layer(java.lang.String l)
Set layer by layer name. |
java.util.ArrayList<IDynamics> |
localDynamics()
IDynamicsBase doesn't implement local dynamics feature |
double |
maxTension()
if maxTension is set to be positive number, it limits the force (distance * tension) is cut off at maxTension. |
ITensionLine |
maxTension(double maxTension)
if maxTension is set to be positive number, it limits the force (distance * tension) is cut off at maxTension if constant is set, maxTension is ignored. |
ITensionLine |
name(java.lang.String nm)
IObject methods |
ITensionLine |
parent()
for IDynamics |
ITensionLine |
parent(IObject par)
setting parent object |
IParticleI |
particle(int i)
alias of pt(int) |
IParticleI |
particle1()
alias of pt1() |
IParticleI |
particle2()
alias of pt2() |
IVec |
pos(int i)
position of particle(i) |
IVec |
pos1()
position of particle1 |
IVec |
pos2()
position of particle2 |
void |
postinteract(java.util.ArrayList<IDynamics> dynamics)
executed after interact(ArrayList |
void |
postupdate()
executed after update(). |
void |
preinteract(java.util.ArrayList<IDynamics> dynamics)
executed before interact(ArrayList |
void |
preupdate()
executed before update(). |
IParticleI |
pt(int i)
getting end point. |
IParticleI |
pt1()
getting end point1. |
IParticleI |
pt2()
getting end point2. |
ITensionLine |
removeTarget(int i)
remove target object. |
ITensionLine |
removeTarget(IObject obj)
remove target object. |
ITensionLine |
setColor(java.awt.Color c)
|
ITensionLine |
setColor(java.awt.Color c,
double alpha)
|
ITensionLine |
setColor(java.awt.Color c,
float alpha)
|
ITensionLine |
setColor(java.awt.Color c,
int alpha)
|
ITensionLine |
setColor(double dgray)
|
ITensionLine |
setColor(double dgray,
double dalpha)
|
ITensionLine |
setColor(double dr,
double dg,
double db)
|
ITensionLine |
setColor(double dr,
double dg,
double db,
double da)
|
ITensionLine |
setColor(float fgray)
|
ITensionLine |
setColor(float fgray,
float falpha)
|
ITensionLine |
setColor(float fr,
float fg,
float fb)
|
ITensionLine |
setColor(float fr,
float fg,
float fb,
float fa)
|
ITensionLine |
setColor(IColor c)
|
ITensionLine |
setColor(IColor c,
double alpha)
|
ITensionLine |
setColor(IColor c,
float alpha)
|
ITensionLine |
setColor(IColor c,
int alpha)
|
ITensionLine |
setColor(int gray)
|
ITensionLine |
setColor(int gray,
int alpha)
|
ITensionLine |
setColor(int r,
int g,
int b)
|
ITensionLine |
setColor(int r,
int g,
int b,
int a)
|
ITensionLine |
setHSBColor(double h,
double s,
double b)
|
ITensionLine |
setHSBColor(double h,
double s,
double b,
double a)
|
ITensionLine |
setHSBColor(float h,
float s,
float b)
|
ITensionLine |
setHSBColor(float h,
float s,
float b,
float a)
|
ITensionLine |
show()
|
IObject |
target(int i)
get target object. |
ITensionLine |
target(IObject targetObj)
add terget object to be updated by this dynamic object. |
int |
targetNum()
get total target number. |
java.util.ArrayList<IObject> |
targets()
get all target objects. |
double |
tension()
tension is a coefficient to convert distance of two points to amount of force. |
ITensionLine |
tension(double tensionIntensity)
tension is a coefficient to convert distance of two points to amount of force. |
void |
update()
behavior definition of updating dynamics in each time frame |
void |
updateTarget()
update all terget objects (should be called when the dynamic object is updated). |
ITensionLine |
weight(double w)
|
ITensionLine |
weight(float w)
|
Methods inherited from class igeo.IObject |
---|
addDynamics, addUserData, addUserData, alpha, alphaInt, attr, attr, awtColor, blue, blueInt, brightness, castStringHashMap, clearDynamics, clearGraphics, clr, defaultAttribute, del, deletDynamics, deleteDynamics, deleteDynamics, deleteGraphic, dynamicsNum, getAWTColor, getColor, getDynamics, getGraphic, getGraphic, getParameter, graphicsNum, gray, grayInt, green, greenInt, grey, greyInt, hue, initGraphic, initObject, isVisible, layer, name, red, redInt, resetGraphic, saturation, server, setParameter, syncColor, syncGraphic, syncVisibility, syncWeight, updateGraphic, userData, userData, userData, userDataNum, visible, weight |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public ITension tensionDynamics
public java.util.ArrayList<IObject> targets
Constructor Detail |
---|
public ITensionLine(IParticleI p1, IParticleI p2)
public ITensionLine(IParticleI p1, IParticleI p2, double tension)
public ITensionLine(IVecI p1, IVecI p2)
public ITensionLine(IVecI p1, IVecI p2, double tension)
Method Detail |
---|
public void initTensionLine(IParticleI p1, IParticleI p2)
public void initTensionLine(IParticleI p1, IParticleI p2, double tension)
public double tension()
ITensionI
tension
in interface ITensionI
public ITensionLine tension(double tensionIntensity)
ITensionI
tension
in interface ITensionI
public boolean constant()
ITensionI
constant
in interface ITensionI
public ITensionLine constant(boolean cnst)
ITensionI
constant
in interface ITensionI
public double maxTension()
maxTension
in interface ITensionI
public ITensionLine maxTension(double maxTension)
maxTension
in interface ITensionI
public IParticleI pt(int i)
pt
in interface ITensionI
public IParticleI particle(int i)
particle
in interface ITensionI
public IVec pos(int i)
pos
in interface ITensionI
public IParticleI pt1()
pt1
in interface ITensionI
public IParticleI particle1()
particle1
in interface ITensionI
public IVec pos1()
pos1
in interface ITensionI
public IParticleI pt2()
pt2
in interface ITensionI
public IParticleI particle2()
particle2
in interface ITensionI
public IVec pos2()
pos2
in interface ITensionI
public ITensionLine parent()
parent
in interface ISubobject
public ITensionLine parent(IObject par)
ISubobject
parent
in interface ISubobject
public java.util.ArrayList<IDynamics> localDynamics()
localDynamics
in interface IDynamics
public ITensionLine target(IObject targetObj)
IDynamics
target
in interface IDynamics
public int targetNum()
targetNum
in interface IDynamics
public IObject target(int i)
target
in interface IDynamics
public java.util.ArrayList<IObject> targets()
targets
in interface IDynamics
public ITensionLine removeTarget(int i)
removeTarget
in interface IDynamics
public ITensionLine removeTarget(IObject obj)
removeTarget
in interface IDynamics
public void updateTarget()
updateTarget
in interface IDynamics
public void interact(java.util.ArrayList<IDynamics> dynamics)
interact
in interface IDynamics
public void update()
update
in interface IDynamics
public void preinteract(java.util.ArrayList<IDynamics> dynamics)
IDynamics
preinteract
in interface IDynamics
public void postinteract(java.util.ArrayList<IDynamics> dynamics)
IDynamics
postinteract
in interface IDynamics
public void preupdate()
IDynamics
preupdate
in interface IDynamics
public void postupdate()
IDynamics
postupdate
in interface IDynamics
public ITensionLine name(java.lang.String nm)
name
in class ICurve
public ITensionLine layer(ILayer l)
IGeometry
layer
in class ICurve
public ITensionLine layer(java.lang.String l)
IGeometry
layer
in class ICurve
public ITensionLine attr(IAttribute at)
IObject
attr
in class ICurve
public ITensionLine hide()
hide
in class ICurve
public ITensionLine show()
show
in class ICurve
public ITensionLine clr(IColor c)
IObject
clr
in class ICurve
public ITensionLine clr(IColor c, int alpha)
IObject
clr
in class ICurve
public ITensionLine clr(IColor c, float alpha)
IObject
clr
in class ICurve
public ITensionLine clr(IColor c, double alpha)
IObject
clr
in class ICurve
public ITensionLine clr(java.awt.Color c)
clr
in class ICurve
public ITensionLine clr(IObject o)
IObject
clr
in class ICurve
public ITensionLine clr(java.awt.Color c, int alpha)
clr
in class ICurve
public ITensionLine clr(java.awt.Color c, float alpha)
clr
in class ICurve
public ITensionLine clr(java.awt.Color c, double alpha)
clr
in class ICurve
public ITensionLine clr(int gray)
clr
in class ICurve
public ITensionLine clr(float fgray)
clr
in class ICurve
public ITensionLine clr(double dgray)
clr
in class ICurve
public ITensionLine clr(int gray, int alpha)
clr
in class ICurve
public ITensionLine clr(float fgray, float falpha)
clr
in class ICurve
public ITensionLine clr(double dgray, double dalpha)
clr
in class ICurve
public ITensionLine clr(int r, int g, int b)
clr
in class ICurve
public ITensionLine clr(float fr, float fg, float fb)
clr
in class ICurve
public ITensionLine clr(double dr, double dg, double db)
clr
in class ICurve
public ITensionLine clr(int r, int g, int b, int a)
clr
in class ICurve
public ITensionLine clr(float fr, float fg, float fb, float fa)
clr
in class ICurve
public ITensionLine clr(double dr, double dg, double db, double da)
clr
in class ICurve
public ITensionLine hsb(float h, float s, float b, float a)
hsb
in class ICurve
public ITensionLine hsb(double h, double s, double b, double a)
hsb
in class ICurve
public ITensionLine hsb(float h, float s, float b)
hsb
in class ICurve
public ITensionLine hsb(double h, double s, double b)
hsb
in class ICurve
public ITensionLine setColor(IColor c)
setColor
in class ICurve
public ITensionLine setColor(IColor c, int alpha)
setColor
in class ICurve
public ITensionLine setColor(IColor c, float alpha)
setColor
in class ICurve
public ITensionLine setColor(IColor c, double alpha)
setColor
in class ICurve
public ITensionLine setColor(java.awt.Color c)
setColor
in class ICurve
public ITensionLine setColor(java.awt.Color c, int alpha)
setColor
in class ICurve
public ITensionLine setColor(java.awt.Color c, float alpha)
setColor
in class ICurve
public ITensionLine setColor(java.awt.Color c, double alpha)
setColor
in class ICurve
public ITensionLine setColor(int gray)
setColor
in class ICurve
public ITensionLine setColor(float fgray)
setColor
in class ICurve
public ITensionLine setColor(double dgray)
setColor
in class ICurve
public ITensionLine setColor(int gray, int alpha)
setColor
in class ICurve
public ITensionLine setColor(float fgray, float falpha)
setColor
in class ICurve
public ITensionLine setColor(double dgray, double dalpha)
setColor
in class ICurve
public ITensionLine setColor(int r, int g, int b)
setColor
in class ICurve
public ITensionLine setColor(float fr, float fg, float fb)
setColor
in class ICurve
public ITensionLine setColor(double dr, double dg, double db)
setColor
in class ICurve
public ITensionLine setColor(int r, int g, int b, int a)
setColor
in class ICurve
public ITensionLine setColor(float fr, float fg, float fb, float fa)
setColor
in class ICurve
public ITensionLine setColor(double dr, double dg, double db, double da)
setColor
in class ICurve
public ITensionLine setHSBColor(float h, float s, float b, float a)
setHSBColor
in class ICurve
public ITensionLine setHSBColor(double h, double s, double b, double a)
setHSBColor
in class ICurve
public ITensionLine setHSBColor(float h, float s, float b)
setHSBColor
in class ICurve
public ITensionLine setHSBColor(double h, double s, double b)
setHSBColor
in class ICurve
public ITensionLine weight(double w)
weight
in class ICurve
public ITensionLine weight(float w)
weight
in class ICurve
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |