archive-org.com » ORG » C » CPNTOOLS.ORG

Total: 415

Choose link from "Titles, links and description words view":

Or switch to "Titles and links view".
  • Place inscriptions << CPN Tools Homepage
    been added the default text for the inscription is TYPE The color set inscription contains the identifier of one of the declared color sets If the color set of a place has not been declared an error message will appear near the place during syntax checking Recall that to declare a color set you must add edit declarations When you enter text into color sets inscriptions the inscription will be completed This auto completion feature highlights the portion of the text which is not entered so that it quickly can be overridden An example The up and down arrow keys can be used to cycle through all color set names that start with the text that has been entered If no text has been entered then the arrow keys can be used to cycle through all of the declared color set names Initial marking inscription The initial marking inscription is a multiset expression that specifies the initial tokens for a place The initial marking inscription is optional Before an initial marking inscription has been added the default text for the inscription is INITMARK The color set for the initial marking expression must match the color set of the place When an initial marking is absent it is equivalent to empty i e the empty multiset Optional time delays If the color set of the place is one of the timed color sets then the initial marking can specify time delays If the initial marking specifies time delays then the initial marking inscription is a timed multiset expression An initial marking time delay is an expression of type integer that is appended to a multi set expression with as a separator The syntax is init mark exp time delay A missing initial marking time delay is equivalent to a zero delay

    Original URL path: http://cpntools.org/documentation/concepts/colors/inscriptions/place_inscriptions (2016-04-26)
    Open archived version from archive


  • Guards << CPN Tools Homepage
    but is preferred as it gives the simulator more opportunities to bind the variables Using a list of expressions does not necessarily have lazy evaluation like andalso as the simulator may find more efficient ways of evaluation Use Guards are used for tests on input arc inscription variables enabling restrictions typically using one or more of the following syntactical elements andalso orelse Guards are also used to restrict values of output arc inscription variables based on the values of the input arc inscription variables Binding variables in guards Variables that are not found in input arc inscriptions can in some cases be bound in the guard In this example the variable i is not on any input arcs but it is bound to the value of the variable j in the guard In some cases it is not possible to bind variables from large color sets in guards In this example i is a variable of an integer color set Side effects Guards are not allowed to have side effects and cannot Contain input output or use commands Update or use reference variables Use the time function Use the random function These restrictions are currently not checked by CPN Tools

    Original URL path: http://cpntools.org/documentation/concepts/colors/inscriptions/guards (2016-04-26)
    Open archived version from archive

  • Code segments << CPN Tools Homepage
    bound elsewhere Each code segment may contain Input pattern optional Output pattern optional Code action mandatory Input pattern An input pattern is a tuple of CPN variables preceded by the keyword input The input pattern lists the CPN variables that can be used in the code action The code action can use the values of these CPN variables but it cannot change them The CPN variables listed in the input pattern can be used in the code action even if you have declared an ML identifier with the same name in the declaration node If the input clause is omitted it implies that no CPN variables can be used in the code action Output pattern An output pattern is a tuple of CPN variables preceded by the keyword output The output pattern lists the CPN variables to be changed as a result of the execution of the code action An output pattern must be a CPN variable or a tuple of CPN variables without repetitions If the output clause is omitted it implies that no CPN variables are calculated Code actions A code action is an ML expression preceded by the keyword action The code action cannot contain any declaration of color sets CPN variables or reference variables It can however apply user declared and predeclared constants operations and functions In addition new functions and constants can be defined for local use by means of let in end The code action is executed as a local declaration in an environment containing the CPN variables specified in the input pattern This guarantees that the code action cannot directly change any CPN variables but only local copies of them When the code action has been executed its result is applied to bind the CPN variables in the output pattern The code action

    Original URL path: http://cpntools.org/documentation/concepts/colors/inscriptions/code_segments (2016-04-26)
    Open archived version from archive

  • Inscriptions in comments << CPN Tools Homepage
    comments In CPN ML a comment begins with and ends with and all text within a comment will not affect the behavior of a net Comments can be added to inscriptions for different purposes In the example on the left a comment has been added to a guard to describe the purpose of the guard In the example on the right a comment is used to remove a guard without

    Original URL path: http://cpntools.org/documentation/concepts/colors/inscriptions/inscriptions_in_comments (2016-04-26)
    Open archived version from archive

  • Colored nets << CPN Tools Homepage
    the CPN ML language for declarations and net inscriptions CPN ML builds on top of Standard ML Some pointers into the documentation of CPN ML and Standard ML can be found here Declarations Color sets simple compound and timed color sets Color set functions Size and complexity of color sets Variables Functions Functions local declarations let in end control structures if then else case Values constants CPN ML identifier Reserved

    Original URL path: http://cpntools.org/documentation/concepts/colors/start?do=addtobook (2016-04-26)
    Open archived version from archive

  • Colored nets << CPN Tools Homepage
    on top of Standard ML Some pointers into the documentation of CPN ML and Standard ML can be found publications here Declarations declarations Colorsets start Color sets simple compound and time timed colour sets timed color sets declarations colorsets colour set functions declarations colorsets size and complexity of co declarations Variables declarations Functions Functions Functions local declarations let in end control structures if then else case declarations Values Values constants

    Original URL path: http://cpntools.org/documentation/concepts/colors/start?do=edit&rev= (2016-04-26)
    Open archived version from archive

  • Declare clause << CPN Tools Homepage
    the versions between 0 1 1 and 0 1 53 are available only as internal releases The declare clause does NOT need to be used in versions 0 1 54 and above unless You have declared product color sets that are Cartesian products of 10 or more sets You have declared record color sets with 10 or more identifiers If you have declared product or record color sets with 10 or more components then you will have to use the declare clause to generate the color set functions that are mentioned below Note it may not be possible to create record or product color sets with more than ca 18 components for more information see bug 731 Declaration Syntax colset name declare id1 id2 idn where for i 1 n idi is one of the following input all ran size ord col of or mult For more details about these functions read more about Color set functions Affected Color Sets The declare clause must be used to declare the following functions Enumerated color sets input Product color sets and record color sets input all ran size ord col mult Union color sets input all ran size ord col of idi

    Original URL path: http://cpntools.org/documentation/concepts/colors/declarations/colorsets/declare_clause (2016-04-26)
    Open archived version from archive

  • Definition of list functions << CPN Tools Homepage
    if a x then rmall a xs else x rmall a xs fun contains true contains x xs false contains ys x xs mem ys x andalso contains ys xs fun contains all true contains all x xs false contains all ys x xs mem ys x andalso contains all rm x ys xs fun intersect ys intersect xs intersect x xs ys if mem ys x then x intersect xs rm x ys else intersect xs ys fun union l1 l2 l1 l2 fun listsub xs xs listsub raise Subtract listsub xs y ys if mem xs y then listsub rm y xs ys else raise Subtract fun ins l x l x fun ins new l x if mem l x then l else ins l x Examples using list functions The examples below use lists of integers but the functions can be used for lists of elements of any type e g lists of strings lists of boolean values lists of records from record color sets etc mem 1 2 3 2 returns true mem 1 2 3 4 returns false remdupl 1 2 3 2 4 2 5 3 returns 1 4 2 5 3 remdupl 1 2 3 returns 1 2 3 rm 3 1 2 3 4 3 5 returns 1 2 4 3 5 rm 3 1 2 4 5 returns 1 2 4 5 rmall 3 1 2 3 4 3 5 returns 1 2 4 5 contains 1 2 3 3 2 returns true contains 1 2 3 3 2 3 returns true contains 1 2 3 3 4 2 returns false contains all 1 2 3 3 2 returns true contains all 1 2 3 3 2 3 returns false contains all 1 2 3 3 4 2 returns false

    Original URL path: http://cpntools.org/documentation/concepts/colors/declarations/colorsets/implementation_of_list_fu (2016-04-26)
    Open archived version from archive



  •