
#ifndef __AUTOSORT_MAIN_H
#define __AUTOSORT_MAIN_H


#include "autogroups.h"

class cNewAutoSort {
private:
  cAutoGroup *workingGroup;
public:
  cNewAutoSort(void);
  virtual ~cNewAutoSort();
  void Dump(int from, int to);
  bool UserBreak (bool CompleteRun = false);
  void CheckDelimiters (void);
  void CheckChannels (bool completeRun = false);
  void Sort(void);
  bool ChannelFitsGroup (int ChIndex, cAutoGroup *group);
  void MoveChannelToGroup (int ChIndex, cAutoGroup *group);
  void MoveGroupToEnd (int ChIndex);
  void MoveGroupBehindGroup (int ChIndex, cAutoGroup *group);
  void AddGroup (cAutoGroup *group);
  void InsGroup (cAutoGroup *group, int ChIndex);
  void DeleteGroup (int ChIndex);
  void ModifyChannelToGroup (int ChIndex, cAutoGroup *group, bool Out = false);
  void SetTimeStamp (int ChIndex);
  const char *InGroup (int ChIndex);
  };


#endif
