I am just trying to create an iterator for a list of class pointers. I searched around for a while and could not find anything regarding this issue. Everything works fine until I try and create the iterator.
Here is the compilation error message I'm getting:
ProcessList.cpp:28:7: error: 'Process' does not refer to a value
            list<Process*>::iterator i;
                 ^
    ./Process.h:3:7: note: declared here
    class Process
          ^
    ProcessList.cpp:28:15: error: expected expression
            list<Process*>::iterator i;
                         ^
    ProcessList.cpp:28:18: error: cannot refer to class template 'iterator' without a template argument list
            list<Process*>::iterator i;
                          ~~^
    /Library/Developer/CommandLineTools/usr/bin/../include/c++/v1/iterator:431:30: note: template is declared here
    struct _LIBCPP_TYPE_VIS_ONLY iterator
                                 ^
    3 errors generated.
Here is my code. The error comes from the ProcessList.cpp code at the bottom:
//main.cpp
#include <iostream>
#include <list>
#include <random>
#include "ProcessList.h"
#include "Generator.h"
using namespace std;
int main()
{
    ProcessList processList(2);
    processList.getProcess(processList.getProcessList());
    return 0;
}
//Process.h
class Process
{
    public: 
        Process();
        void setPID(int PID);
        int getPID();
        int calculateNumberOfCycles();
        int getNumberOfCycles();
        int calculateMemorySize();
        int getMemorySize();
    private:
        static int number_of_processes;
        int PID;
        int number_of_cycles;
        int memory_size;
};
//Process.cpp
#include <iostream>
#include "Process.h"
using namespace std;
int Process::number_of_processes = 0;//define static variable
//Constructor
Process::Process()
{
    cout << "Process Constructor" << endl;
    PID = number_of_processes;
    number_of_cycles = number_of_processes;
    memory_size = number_of_processes;
    number_of_processes++;
    //number_of_cycles = setNumberOfCycles;
    //memory_size = setMemorySize;
}
//PID Setter
void Process::setPID(int PID)
{
}
//PID Getter
int Process::getPID()
{
    return PID;
}
//Generates a random number of cycles based od the defined variables
int Process::calculateNumberOfCycles()
{
    return 0;
}
//Returns the number of cycles of the process
int Process::getNumberOfCycles()
{
    return number_of_cycles;
}
//Generates a random amount of memory based on the defined variables
int Process::calculateMemorySize()
{
    return 0;
}
//Returns the amount of memory for the process
int Process::getMemorySize()
{
    return memory_size;
}
//ProcessList.h
#include <list>
#include "Process.h"
 using namespace std;
class ProcessList
{
    private:
        list<Process*> processList;
    public:
        ProcessList(int number_of_processes_to_create);
        list<Process*> getProcessList();
        Process* createProcess();
        void getProcess(list<Process*> list);
};
//ProcessList.cpp
 #include <iostream>
 #include "ProcessList.h"
 using namespace std;
ProcessList::ProcessList(int number_of_processes_to_create)
{
    processList.push_back(createProcess());
}
Process* ProcessList::createProcess()
{
    Process *process = new Process();
    return process;
}
list<Process*> ProcessList::getProcessList()
{
    return processList;
}
void ProcessList::getProcess(list<Process*> list)
{
    list<Process*>::iterator i;
}
 
    