return the flavor definition - Maple Help

Online Help

All Products    Maple    MapleSim


Home : Support : Online Help : Programming : Random Objects : RandomTools package : Commands : RandomTools/GetFlavor

RandomTools[GetFlavor] - return the flavor definition

Calling Sequence

GetFlavor(flvr)

Parameters

flvr

-

symbol; represents a flavor in the form of a procedure or module

Description

• 

The GetFlavor(flvr) function, where flvr specifies a flavor that is  known to function Generate, returns the procedure or module that defines the behavior of the flavor.

  

If the flavor is not recognized by Generate, an exception is returned.

• 

This function is part of the RandomTools package, and so it can be used in the form GetFlavor(..) only after executing the command with(RandomTools). However, it can always be accessed through the long form of the command by using the form RandomTools[GetFlavor](..).

Examples

withRandomTools:

AddFlavorA=rand1..20:

GenerateA

15

(1)

GetFlavorA

procprocoptionbuiltin=RandNumberInterface;end proc6,20,5+1end proc

(2)

GetFlavorinteger

procrange::integer..integer:=−499999999994..499999999994, $...end proc

(3)

memberA,GetFlavors

true

(4)

See Also

module, procedure, RandomTools, RandomTools[AddFlavor], RandomTools[Generate], RandomTools[GetFlavors], RandomTools[HasFlavor], RandomTools[RemoveFlavor]


Download Help Document

Was this information helpful?



Please add your Comment (Optional)
E-mail Address (Optional)
What is ? This question helps us to combat spam