toDimensionSymbol static method

String toDimensionSymbol(
  1. int dimensionValue
)

Converts the dimension value to a dimension symbol, for example, TRUE => 'T' .

@param dimensionValue a number that can be stored in the IntersectionMatrix . Possible values are {TRUE, FALSE, DONTCARE, 0, 1, 2}. @return a character for use in the string representation of an IntersectionMatrix. Possible values are {T, F, * , 0, 1, 2} .

Implementation

static String toDimensionSymbol(int dimensionValue) {
  switch (dimensionValue) {
    case FALSE:
      return SYM_FALSE;
    case TRUE:
      return SYM_TRUE;
    case DONTCARE:
      return SYM_DONTCARE;
    case P:
      return SYM_P;
    case L:
      return SYM_L;
    case A:
      return SYM_A;
  }
  throw ArgumentError("Unknown dimension value: $dimensionValue");
}