Ejemplo n.º 1
0
 public PartialSession(PartialData data)
 {
     Id                        = data.Id;
     _chatId                   = data.ChatId;
     _name                     = data.Name;
     _batchCount               = data.BatchCount;
     _dataSource               = new PartialSource(data.DataSource);
     _isRandomOrder            = data.IsRandomOrder;
     _dataOutput               = new PartialOutput(data.DataOutput);
     _options                  = data.Options;
     _canAddOptions            = data.CanAddOptions;
     _autoOrderOptions         = data.AutoOrderOptions;
     _canSelectMultipleOptions = data.CanSelectMultipleOptions;
 }
        public Menu NextMenu(PartialSource partialSource)
        {
            switch (_type)
            {
            case null:
                return(new CreateSessionOutputTypeMenu(DataOutput.AllowedDataOutput(partialSource.Type)));

            case DataOutput.DataOutputTypes.SubDirectory:
                return(null);

            case DataOutput.DataOutputTypes.Json when _jsonFileName == null:
                return(new CreateSessionOutputJsonFileName());

            case DataOutput.DataOutputTypes.Json when _jsonTagKey == null:
                return(new CreateSessionOutputJsonTagKey());

            default:
                throw new ArgumentOutOfRangeException();
            }
        }
Ejemplo n.º 3
0
 public PartialSession(long chatId)
 {
     _chatId     = chatId;
     _dataSource = new PartialSource();
     _dataOutput = new PartialOutput();
 }