code: def set_typ(self, refobj, typ):
          
          try:
              enum = JB_ReftrackNode.types.index(typ)
          except ValueError:
              raise ValueError("The given type %s could not be found in available types: %" % (typ, JB_ReftrackNode.types))
          cmds.setAttr("%s.type" % refobj, enum)
docs: Set the type of the given refobj
  
          :param refobj: the reftrack node to edit
          :type refobj: refobj
          :param typ: the entity type
          :type typ: str
          :returns: None
          :rtype: None
          :raises: ValueError