import{u as e}from"./logger-D0y9iaZX.js";const t=`HEARTBEAT_OK`,n=`NO_REPLY`,r=new Map,i=new Map;function a(t){let n=r.get(t);if(n)return n;let i=e(t),a=RegExp(`^\\s*${i}\\s*$`);return r.set(t,a),a}function o(t){let n=i.get(t);if(n)return n;let r=e(t),a=RegExp(`(?:^|\\s+|\\*+)${r}\\s*$`);return i.set(t,a),a}function s(e,t=n){return e?a(t).test(e):!1}function c(e,t=n){return e.replace(o(t),``).trim()}function l(e,t=n){if(!e)return!1;let r=e.trimStart();if(!r||r!==r.toUpperCase())return!1;let i=r.toUpperCase();if(!i||i.length<2||/[^A-Z_]/.test(i))return!1;let a=t.toUpperCase();return a.startsWith(i)?i.includes(`_`)?!0:a===`NO_REPLY`&&i===`NO`:!1}export{c as a,s as i,n,l as r,t};
