How does this translation rule break down?

Unanswered Question
Aug 6th, 2007

In this rule;

rule 1 /\(.*\)/ /3000/

I'm having trouble understanding the syntax for


I've looked at the documentation which explains that "\" slices up the number (whatever that means). The parenthesis indicate which matched numbers to keep, but what does it mean when we're saying that we want to keep ".*\" ? How does the last character of "\" work, why does it need to be there?


I have this problem too.
0 votes
  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 0 (0 ratings)
Paolo Bevilacqua Mon, 08/06/2007 - 10:05


slice means "cut the number in sets", the ones that are in parenthesis are saved, others are not. The ones saved can be recalled in the in replaced part, however your example does not do that. What your example does is to prepend 3000 to any number, an can be rewritten more concisely as:

rule 1 // /3000/

The backlashes are simply need to quote parenthesis.

shikamarunara Mon, 08/06/2007 - 10:24

No, actually, this doesn't work. When you try to use two forward slashes in succession, IOS kicks it back as having ammended the digits, not replaced.



This Discussion