タイムスタンプ、現在のフロア、および目的のフロアによってリクエストを読み取る機能がありますが、期待どおりに出力されません。
すべてのメンバー値が正しく出力されています: タイムスタンプ、現在のフロア、ブール値を除く目的のフロア。
bool は、私の方向に対して 1 または 0 の代わりに 205 を出力します。
Elevator::readRequests()
{
  ifstream myStream("T1.txt");
while(!myStream.eof())
{
    int timestamp ,currentFloor, destinationFloor;
    myStream >> timestamp >> currentFloor >> destinationFloor;
    //cout<< endl <<"The current timestamp is "<< timestamp << "The current floor is " << currentFloor 
    //  << " and the destination floor is " << destinationFloor << endl << endl;
    //cout<< endl;
    reqNode *temp = new reqNode;
    //initialize request node object
    temp->timestamp = timestamp;
    temp->start = currentFloor;
    temp->destination = destinationFloor;
    temp->start_time = -1;
    temp->finish_time = -1;
    temp->calculate_priority();
    if(temp->start < temp->destination)
        temp->set_dir(true);
    else
        temp->set_dir(false);
    request.push(*temp);//push nodes into the request bank
}
int i = 0;
while( !request.empty() )
{
    cout << "Node " << i << " : " << request.front().timestamp << " " <<    request.front().start << " " << request.front().destination
        << " " <<  request.front().direction << endl;
    request.pop();//popping the request in order to test
    i++;
}
}
出力を取得しようとしています:
ノード番号: タイムスタンプ。現在(ユーザーフロア)。目的地(ユーザーフロア)。方向(ユーザーが向いている)。
Node 0 : 1 3 7 1
Node 1 : 1 2 9 1
Node 2 : 1 7 9 1
Node 3 : 2 4 6 1
Node 4 : 2 4 8 1
Node 5 : 2 1 17 1
Node 6 : 5 1 15 1
Node 7 : 5 5 1 0
Node 8 : 6 17 4 0
Node 9 : 6 4 17 1
代わりに、出力として取得しています:
Node 0 : 1 3 7 205
Node 1 : 1 2 9 205
Node 2 : 1 7 9 205
Node 3 : 2 4 6 205
Node 4 : 2 4 8 205
Node 5 : 2 1 17 205 
Node 6 : 5 1 15 205
Node 7 : 5 5 1 205
Node 8 : 6 17 4 205
Node 9 : 6 4 17 205
これはファイル T1.txt です。
1 3 7
1 2 9
1 7 9
2 4 6
2 4 8
2 1 17
5 1 15
5 5 1
6 17 4
6 4 17