I am currently creating a programme that will be based on a virtual cell simulation. For this I have seperate classes called machine, worksettingstation, robot and component. I need to be able to pass a component through each class depending on where it is in the cell. How would I create a property to do this? Also when it leaves the specific class it will return null as the component has moved. This will eventually move to a WPF but at the moment I'm just trying to show it in a simple class.
Is there a way I can simply just add a new property to each class and then reference it to the class called component and do a simple check to see if it has been passed on yet?