"use strict";
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
const ModelUtil = require("../../util/ModelUtil.js");
function u(e) {
  if (ModelUtil.is(e, "bpmn:FlowElement") || ModelUtil.is(e, "bpmn:Participant") || ModelUtil.is(e, "bpmn:Lane") || ModelUtil.is(e, "bpmn:SequenceFlow") || ModelUtil.is(e, "bpmn:MessageFlow") || ModelUtil.is(e, "bpmn:DataInput") || ModelUtil.is(e, "bpmn:DataOutput"))
    return "name";
  if (ModelUtil.is(e, "bpmn:TextAnnotation"))
    return "text";
  if (ModelUtil.is(e, "bpmn:Group"))
    return "categoryValueRef";
}
function a(e) {
  var r = e.categoryValueRef;
  return r && r.value || "";
}
function p(e) {
  var r = e.businessObject, n = u(r);
  if (n)
    return n === "categoryValueRef" ? a(r) : r[n] || "";
}
exports.getLabel = p;
