public static bool PolygonTagTypeEquals(this Polygon poly, PolygonTagType tagType)
 {
     if (poly.Tag is PolygonTag pt)
     {
         return(pt.PolygonTagType.Equals(tagType));
     }
     return(false);
 }
 public static bool PolygonTagEquals(this Polygon poly, PolygonTagType tagType, string str)
 {
     return(poly.PolygonTagTypeEquals(tagType) &&
            poly.PolygonTagStringEquals(str));
 }