Returns the first matching meaning of the specified types. Useful for determining which of several possible meanings this node has. @param types an array of types to check @return the first matching type, or Types#UNKNOWN if no match is found
(int[] types)
| 136 | * @return the first matching type, or {@link Types#UNKNOWN} if no match is found |
| 137 | */ |
| 138 | public int getMeaningAs(int[] types) { |
| 139 | |
| 140 | for (int type : types) { |
| 141 | if (isA(type)) { |
| 142 | return type; |
| 143 | } |
| 144 | } |
| 145 | |
| 146 | return Types.UNKNOWN; |
| 147 | } |
| 148 | |
| 149 | //--------------------------------------------------------------------------- |
| 150 | // TYPE SUGAR |