|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.joone.util.AbstractConverterPlugIn
org.joone.util.ConverterPlugIn
org.joone.util.ToBinaryPlugin
public class ToBinaryPlugin
This plug-in converts 10-base data to binary format. The plug-in ingnores the broken part (the part after the . ) for non-integer numbers. It works correct for positive as well as for negative numbers.
Field Summary |
---|
Fields inherited from class org.joone.util.AbstractConverterPlugIn |
---|
pluginListeners |
Constructor Summary | |
---|---|
ToBinaryPlugin()
Creates a new instance of ToBinaryPlugin |
|
ToBinaryPlugin(java.lang.String anAdvancedSerieSelector)
Creates a new instance of ToBinaryPlugin |
Method Summary | |
---|---|
protected boolean |
apply()
Applies all the conversions on the patterns contained by AbstractConverterPlugIn.InputVector |
protected boolean |
convert(int serie)
Applies the conversion on the Nth serie of the buffered pattern data. |
protected double[] |
getBinary(double aNumber)
Converts a number to a binary number (the part after the . |
double |
getLowerBit()
Gets the value used for the lower bit. |
double |
getUpperBit()
Gets the value used for the upper bit. |
void |
setLowerBit(double aValue)
Sets the value for the lower bit. |
void |
setUpperBit(double aValue)
Sets the value for the upper bit. |
Methods inherited from class org.joone.util.ConverterPlugIn |
---|
isApplyEveryCycle, newCycle, setApplyEveryCycle |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ToBinaryPlugin()
public ToBinaryPlugin(java.lang.String anAdvancedSerieSelector)
anAdvancedSerieSelector
- the advanced serie selector to use.setAdvancedSerieSelector()
Method Detail |
---|
protected boolean convert(int serie)
AbstractConverterPlugIn
AbstractConverterPlugIn.getInputVector()
method. The result is a
Vector
of Pattern
objects which this method should use by converting
the requested serie.
convert
in class AbstractConverterPlugIn
serie
- the serie to convertprotected boolean apply()
AbstractConverterPlugIn
AbstractConverterPlugIn.InputVector
apply
in class AbstractConverterPlugIn
protected double[] getBinary(double aNumber)
aNumber
- the number to convert.
public void setUpperBit(double aValue)
aValue
- the value to use for the upper bit.public double getUpperBit()
public void setLowerBit(double aValue)
aValue
- the value to use for the lower bit.public double getLowerBit()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |