"use strict";

Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.NCartridgeType = void 0;
let NCartridgeType = exports.NCartridgeType = /*#__PURE__*/function (NCartridgeType) {
  NCartridgeType[NCartridgeType["none"] = -1] = "none";
  NCartridgeType[NCartridgeType["white"] = 0] = "white";
  NCartridgeType[NCartridgeType["yellow"] = 1] = "yellow";
  NCartridgeType[NCartridgeType["green"] = 2] = "green";
  NCartridgeType[NCartridgeType["blue"] = 3] = "blue";
  NCartridgeType[NCartridgeType["pink"] = 7] = "pink";
  NCartridgeType[NCartridgeType["l1"] = 13] = "l1";
  NCartridgeType[NCartridgeType["l2"] = 12] = "l2";
  NCartridgeType[NCartridgeType["l3"] = 10] = "l3";
  NCartridgeType[NCartridgeType["l4"] = 6] = "l4";
  NCartridgeType[NCartridgeType["l5"] = 8] = "l5";
  NCartridgeType[NCartridgeType["l6"] = 5] = "l6";
  NCartridgeType[NCartridgeType["l7"] = 9] = "l7";
  NCartridgeType[NCartridgeType["l8"] = 11] = "l8";
  NCartridgeType[NCartridgeType["m1"] = 101] = "m1";
  NCartridgeType[NCartridgeType["m2"] = 102] = "m2";
  NCartridgeType[NCartridgeType["m3"] = 103] = "m3";
  NCartridgeType[NCartridgeType["m4"] = 104] = "m4";
  NCartridgeType[NCartridgeType["m5"] = 105] = "m5";
  NCartridgeType[NCartridgeType["m6"] = 106] = "m6";
  NCartridgeType[NCartridgeType["m7"] = 107] = "m7";
  NCartridgeType[NCartridgeType["m8"] = 108] = "m8";
  NCartridgeType[NCartridgeType["question"] = 4] = "question";
  NCartridgeType[NCartridgeType["n"] = 14] = "n";
  return NCartridgeType;
}({});
(function (_NCartridgeType) {
  function isValidCartridge(type) {
    switch (type) {
      case NCartridgeType.white:
      case NCartridgeType.yellow:
      case NCartridgeType.green:
      case NCartridgeType.blue:
      case NCartridgeType.pink:
      case NCartridgeType.l1:
      case NCartridgeType.l2:
      case NCartridgeType.l3:
      case NCartridgeType.l4:
      case NCartridgeType.l5:
      case NCartridgeType.l6:
      case NCartridgeType.l7:
      case NCartridgeType.l8:
      case NCartridgeType.m1:
      case NCartridgeType.m2:
      case NCartridgeType.m3:
      case NCartridgeType.m4:
      case NCartridgeType.m5:
      case NCartridgeType.m6:
      case NCartridgeType.m7:
      case NCartridgeType.m8:
      case NCartridgeType.n:
        return true;
    }
    return false;
  }
  _NCartridgeType.isValidCartridge = isValidCartridge;
  function isMiniCartridge(type) {
    switch (type) {
      case NCartridgeType.m1:
      case NCartridgeType.m2:
      case NCartridgeType.m3:
      case NCartridgeType.m4:
      case NCartridgeType.m5:
      case NCartridgeType.m6:
      case NCartridgeType.m7:
      case NCartridgeType.m8:
        return true;
    }
    return false;
  }
  _NCartridgeType.isMiniCartridge = isMiniCartridge;
  function isLabelCartridge(type) {
    switch (type) {
      case NCartridgeType.l1:
      case NCartridgeType.l2:
      case NCartridgeType.l3:
      case NCartridgeType.l4:
      case NCartridgeType.l5:
      case NCartridgeType.l6:
      case NCartridgeType.l7:
      case NCartridgeType.l8:
        return true;
    }
    return false;
  }
  _NCartridgeType.isLabelCartridge = isLabelCartridge;
  function isStickyCartridge(type) {
    switch (type) {
      case NCartridgeType.white:
      case NCartridgeType.yellow:
      case NCartridgeType.green:
      case NCartridgeType.blue:
      case NCartridgeType.pink:
      case NCartridgeType.l1:
      case NCartridgeType.l2:
      case NCartridgeType.l3:
      case NCartridgeType.l4:
      case NCartridgeType.l5:
      case NCartridgeType.l6:
      case NCartridgeType.l7:
      case NCartridgeType.l8:
      case NCartridgeType.m1:
      case NCartridgeType.m2:
      case NCartridgeType.m3:
      case NCartridgeType.m4:
      case NCartridgeType.m5:
      case NCartridgeType.m6:
      case NCartridgeType.m7:
      case NCartridgeType.m8:
      case NCartridgeType.n:
        return true;
    }
    return false;
  }
  _NCartridgeType.isStickyCartridge = isStickyCartridge;
  function getCartridgeName(type) {
    switch (type) {
      case NCartridgeType.white:
        return "W";
      case NCartridgeType.yellow:
        return "Y";
      case NCartridgeType.green:
        return "G";
      case NCartridgeType.blue:
        return "B";
      case NCartridgeType.pink:
        return "P";
      case NCartridgeType.l1:
        return "L1";
      case NCartridgeType.l2:
        return "L2";
      case NCartridgeType.l3:
        return "L3";
      case NCartridgeType.l4:
        return "L4";
      case NCartridgeType.l5:
        return "L5";
      case NCartridgeType.l6:
        return "L6";
      case NCartridgeType.l7:
        return "L7";
      case NCartridgeType.l8:
        return "L8";
      case NCartridgeType.m1:
        return "m1";
      case NCartridgeType.m2:
        return "m2";
      case NCartridgeType.m3:
        return "m3";
      case NCartridgeType.m4:
        return "m4";
      case NCartridgeType.m5:
        return "m5";
      case NCartridgeType.m6:
        return "m6";
      case NCartridgeType.m7:
        return "m7";
      case NCartridgeType.m8:
        return "m8";
      case NCartridgeType.question:
        return "?";
      case NCartridgeType.n:
        return "n";
      default:
        return "X";
    }
  }
  _NCartridgeType.getCartridgeName = getCartridgeName;
  function getCartridgeType(value) {
    if (typeof value === "number") {
      let result = value;
      if (NCartridgeType[result] === undefined) {
        return NCartridgeType.none;
      }
      return result;
    } else {
      switch (value) {
        case "W":
          return NCartridgeType.white;
        case "Y":
          return NCartridgeType.yellow;
        case "G":
          return NCartridgeType.green;
        case "B":
          return NCartridgeType.blue;
        case "P":
          return NCartridgeType.pink;
        case "L1":
          return NCartridgeType.l1;
        case "L2":
          return NCartridgeType.l2;
        case "L3":
          return NCartridgeType.l3;
        case "L4":
          return NCartridgeType.l4;
        case "L5":
          return NCartridgeType.l5;
        case "L6":
          return NCartridgeType.l6;
        case "L7":
          return NCartridgeType.l7;
        case "L8":
          return NCartridgeType.l8;
        case "m1":
          return NCartridgeType.m1;
        case "m2":
          return NCartridgeType.m2;
        case "m3":
          return NCartridgeType.m3;
        case "m4":
          return NCartridgeType.m4;
        case "m5":
          return NCartridgeType.m5;
        case "m6":
          return NCartridgeType.m6;
        case "m7":
          return NCartridgeType.m7;
        case "m8":
          return NCartridgeType.m8;
        case "?":
          return NCartridgeType.question;
        case "N":
          return NCartridgeType.n;
        default:
          return NCartridgeType.none;
      }
    }
  }
  _NCartridgeType.getCartridgeType = getCartridgeType;
})(NCartridgeType || (exports.NCartridgeType = NCartridgeType = {}));
//# sourceMappingURL=NCartridgeType.js.map