isStop - Maple Help
For the best experience, we recommend viewing online help using Google Chrome or Microsoft Edge.

Online Help

All Products    Maple    MapleSim


Algebraic.isStop

check if the current Algebraic represents a Maple stop expression

 

Calling Sequence

Description

Examples

Calling Sequence

boolean isStop() throws MapleException

Description

• 

The isStop function returns true if the current Algebraic object represents a Maple stop expression.

• 

A stop expression is generated when quit, stop or done is executed by the Maple session.  Usually it is used to indicate that the Maple session should be terminated.

Examples

import com.maplesoft.openmaple.*;

import com.maplesoft.externalcall.MapleException;

class Example

{

    public static void main( String notused[] ) throws MapleException

    {

        String[] mapleArgs = { "java" };

        Engine engine = new Engine( mapleArgs, new EngineCallBacksDefault(), null, null );

        Algebraic a1 = engine.evaluate( "1:" );

        if ( a1.isStop() )

        {

            System.out.println( "Stop" );

        }

        else

        {

            System.out.println( "Not Stop" );

        }

        a1 = engine.evaluate( "quit:" );

        if ( a1.isStop() )

        {

            System.out.println( "Stop" );

        }

        else

        {

            System.out.println( "Not Stop" );

        }

    }

}

Executing this code should produce the following output.

Not Stop

Stop

See Also

ExternalCalling/Java/MapleException

OpenMaple

OpenMaple/Java/Algebraic

OpenMaple/Java/API

quit