$tok

By simplicity on Sep 15, 2007

A simple identifier that uses everyday tokens through properties.

$tok(string,operation,N,pos,C).calc performs a $calc operation.

$tok(string,N,pos,C).add adds a parameter to the string.

$tok(string,N,N2,C).repall replaces all parameters in the string matching your criteria.

$tok(sting,N,N1,pos,C).rep replaces the the previous parameter with a new one.

$tok(string,pos,C).rem deletes a target in the string

alias tok {
  if (isid) { 
    if ($prop iswm calc) { return $puttok($$1,$calc($gettok($$1,$$4,$$5) $$2 $$3),$$4,$$5) }
    if ($prop iswm add) { return $instok($$1,$$2,$findtok($$1,$$3,$$4),$$4) }
    if ($prop iswm rem) { return $deltok($$1,$fintok($$1,$$2,$$4),$$3) }
    if ($prop iswm rep) { return $replace($$1,$gettok($$1,$$4,$$5),$$3) }
    if ($prop iswm repall) { return $replace($$1,$findtok($$1,$$2,$$4),$$3) }
  }
}

Comments

Sign in to comment.
Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.