Numeric.isUnnamedZero - check if the value stored in the Numeric is equal to zero
|
Calling Sequence
|
|
boolean isUnnamedZero() throws MapleException
|
|
Description
|
|
•
|
The isUnnamedZero function returns true if the value represented by the current Numeric object is zero and false otherwise.
|
|
|
Examples
|
|
import com.maplesoft.openmaple.*;
|
import com.maplesoft.externalcall.MapleException;
|
class Example
|
{
|
public static void main( String notused[] ) throws MapleException
|
{
|
String mapleArgs[];
|
Engine engine;
|
Numeric n;
|
short s;
|
mapleArgs = new String[1];
|
mapleArgs[0] = "java";
|
engine = new Engine( mapleArgs, new EngineCallBacksDefault(),
|
null, null );
|
n = (Numeric)engine.evaluate( "0:" );
|
System.out.println( n.isUnnamedZero() );
|
n = (Numeric)engine.evaluate( "1:" );
|
System.out.println( n.isUnnamedZero() );
|
n = (Numeric)engine.evaluate( "0.:" );
|
System.out.println( n.isUnnamedZero() );
|
n = (Numeric)engine.evaluate( "1.:" );
|
System.out.println( n.isUnnamedZero() );
|
}
|
}
|
|
|
Executing this code produces the following output.
|
|
Download Help Document
Was this information helpful?