Many amenities can be mapped as areas.
[potlatch2.git] / it / sephiroth / expr / TokenType.as
1 package it.sephiroth.expr
2 {
3         public final class TokenType
4         {
5                 public static const ADD: int = 1;
6                 public static const SUB: int = 2;
7                 public static const MUL: int = 3;
8                 public static const DIV: int = 4;
9                 public static const NUM: int = 5;
10                 public static const IDENT: int = 6;
11                 public static const LEFT_PAR: int = 7;
12                 public static const RIGHT_PAR: int = 8;
13                 public static const COMMA: int = 9;
14                 public static const NULL: int = 0;
15                 public static const EOF: int = -1;
16                 
17                 public static function typeToString( type: int ): String
18                 {
19                         switch( type )
20                         {
21                                 case 0:         return "NULL";
22                                 case 1:         return "ADD";
23                                 case 2:         return "SUB";
24                                 case 3:         return "MUL";
25                                 case 4:         return "DIV";
26                                 case 5:         return "NUM";
27                                 case 6:         return "IDENT";
28                                 case 7:         return "LEFT_PAR";
29                                 case 8:         return "RIGHT_PAR";
30                                 case 9:         return "COMMA";
31                                 default:        return "EOF";
32                         }
33                         
34                         return null;
35                 }
36         }
37 }