From 2fba7cc73c74540bb597501f1accfc3edc7a3ad9 Mon Sep 17 00:00:00 2001
From: jsiegle <joshs@alleninstitute.org>
Date: Mon, 22 Sep 2014 16:41:53 -0700
Subject: [PATCH] Get it to compile

---
 Source/Processors/Channel.cpp    |  4 +++-
 Source/Processors/Channel.h      |  6 ++++-
 Source/Processors/RecordNode.cpp | 40 ++++++++++++++++----------------
 Source/Processors/RecordNode.h   |  7 ++++++
 4 files changed, 35 insertions(+), 22 deletions(-)

diff --git a/Source/Processors/Channel.cpp b/Source/Processors/Channel.cpp
index 11de6fc64..1136a0e1f 100644
--- a/Source/Processors/Channel.cpp
+++ b/Source/Processors/Channel.cpp
@@ -35,15 +35,17 @@ Channel::Channel(GenericProcessor* p, int n) : num(n), eventType(0), processor(p
 Channel::Channel(const Channel& ch)
 {
     processor = ch.processor;
+    isEventChannel = ch.isEventChannel;
     isEnabled = ch.isEnabled;
     isMonitored = false;
-    type = ch.type;
+    isADCchannel = ch.isADCchannel;
     sampleRate = ch.sampleRate;
     bitVolts = ch.bitVolts;
     name = ch.name;
     eventType = ch.eventType;
     nodeId = ch.nodeId;
     num = ch.num;
+
     originalStream = ch.originalStream;
     originalChannel = ch.originalChannel;
 
diff --git a/Source/Processors/Channel.h b/Source/Processors/Channel.h
index c502fffba..27df965a7 100644
--- a/Source/Processors/Channel.h
+++ b/Source/Processors/Channel.h
@@ -104,13 +104,17 @@ public:
     /** Pointer to the channel's parent processor. */
     GenericProcessor* processor;
 
+    int originalStream;
+    int originalChannel;
 
 
     // crucial information:
     float sampleRate;
     channelType type;
     
-    // boolean values:
+     // boolean values:
+    bool isEventChannel;
+    bool isADCchannel;
     bool isMonitored;
     bool isEnabled;
 
diff --git a/Source/Processors/RecordNode.cpp b/Source/Processors/RecordNode.cpp
index 249475f1c..8c1f3ab55 100755
--- a/Source/Processors/RecordNode.cpp
+++ b/Source/Processors/RecordNode.cpp
@@ -212,31 +212,31 @@ void RecordNode::addInputChannel(GenericProcessor* sourceNode, int chan)
 
 void RecordNode::updateFileName(Channel* ch)
 {
-    String filename = rootFolder.getFullPathName();
-    filename += rootFolder.separatorString;
+    // String filename = rootFolder.getFullPathName();
+    // filename += rootFolder.separatorString;
 
-    if (!ch->getType() == EVENT_CHANNEL)
-    {
-        filename += ch->nodeId;
-        filename += "_";
-        filename += ch->name;
+    // if (!ch->getType() == EVENT_CHANNEL)
+    // {
+    //     filename += ch->nodeId;
+    //     filename += "_";
+    //     filename += ch->name;
 
-        if (appendTrialNum)
-        {
-            filename += "_";
-            filename += trialNum;
-        }
+    //     if (appendTrialNum)
+    //     {
+    //         filename += "_";
+    //         filename += trialNum;
+    //     }
 
-        filename += ".continuous";
-    }
-    else
-    {
-        filename += "all_channels.events";
-    }
+    //     filename += ".continuous";
+    // }
+    // else
+    // {
+    //     filename += "all_channels.events";
+    // }
 
 
-    ch->filename = filename;
-    ch->file = 0;
+    // ch->filename = filename;
+    // ch->file = 0;
 
 
     //std::cout << "Updating " << filename << std::endl;
diff --git a/Source/Processors/RecordNode.h b/Source/Processors/RecordNode.h
index ab8b3c7a3..96d47f067 100755
--- a/Source/Processors/RecordNode.h
+++ b/Source/Processors/RecordNode.h
@@ -125,6 +125,13 @@ public:
         return rootFolder;
     }
 
+    void appendTrialNumber(bool);
+    
+    void updateTrialNumber();
+
+       /** Generate filename for a given channel */
+    void updateFileName(Channel* ch);
+
 	/** Adds a Record Engine to use
 	*/
     void registerRecordEngine(RecordEngine* engine);
-- 
GitLab