|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectdspl.intermediate.variable.primitive.Complex
public class Complex
Complex is the primitive object wrapper for Complex #'s In DSPL, all other primitive atomic objects (float, int, byte, etc) already have equivalent java classes that can be substitued in the Variable's valueOf field. The one exception is the complex type, thus the raison-d'etre for the Complex class.
| Field Summary | |
|---|---|
float |
imag
The imaginary part of the complex number |
float |
real
The real part of the complex number |
| Constructor Summary | |
|---|---|
Complex(float real,
float imag)
|
|
Complex(java.lang.String real,
java.lang.String imag)
Constructor used to create based on string representationso of the imaginary and real parts of the complex number. |
|
| Method Summary | |
|---|---|
java.lang.String |
toString()
Returns a string representation of the complex number in the form of "a + bi" or "a - bi" depending on the sign of imag |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public float real
public float imag
| Constructor Detail |
|---|
public Complex(float real,
float imag)
real - Real part of the complex #imag - Imag part of the complex #
public Complex(java.lang.String real,
java.lang.String imag)
real - imag - | Method Detail |
|---|
public java.lang.String toString()
toString in class java.lang.Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||