grep "#include" *.c* | grep -v "<" - | grep -v "//" - > includes.txt
grep "#include" *.h | grep -v "<" - | grep -v "//" - >> includes.txt
Then modify the .txt file in VI and save it as .dot
digraph yms_dep {
allocate_main -> Yard;
allocate_main -> Slot;
allocate_main -> yard_shm_daem;
allocate_main -> cont;
allocate_main -> ContainerHelper;
allocate_main -> ECShmem;
allocate_main -> YtoHtml;
Allocation -> Slot;
Allocation -> XMLListener;
Allocation -> Allocation;
AllocationFilter -> AllocationFilter;
AllocationFilter -> Slot;
allocationtimes -> allocationtimes;
alloclistener -> ServerSocket;
alloclistener -> SocketException;
alloclistener -> Slot;
alloclistener -> Yard;
alloclistener -> alloclistener;
ban -> ContainerHelper;
ban -> ban;
bannedSlots -> ContainerHelper;
bannedSlots -> bannedSlots;
berths -> ContainerHelper;
berths -> stat;
berths -> Vessels;
berths -> VesselNotFoundException;
berths -> berths;
BestAlloc -> BestAlloc;
BestAllocsList -> BestAllocsList;
BestAllocsList -> Lock;
Block -> ReeferRow;
Block -> ContainerNotFoundException;
Block -> Block;
Ches -> Ches;
client -> ClientSocket;
client -> SocketException;
ClientSocket -> ClientSocket;
ClientSocket -> SocketException;
concreteObserver -> ContainerHelper;
concreteObserver -> concreteObserver;
concreteSubject -> concreteSubject;
Conslist -> ContainerHelper;
Conslist -> Statistics;
Conslist -> SocketException;
Conslist -> Lock;
Conslist -> tcp_msg;
Conslist -> Message;
Conslist -> Conslist;
Consol -> NullWiException;
Consol -> XMLListener;
Consol -> Ches;
Consol -> Consol;
ContainerHelper -> ContainerHelper;
ContainerHelper -> Yard;
ContainerHelper -> ContainerNotFoundException;
CostFunction -> CostFunction;
ctr_key_dump -> Yard;
ctr_key_dump -> Slot;
ctr_key_dump -> yard_shm_daem;
ctr_key_dump -> cont;
ctr_key_dump -> ContainerHelper;
ctr_key_dump -> ECShmem;
ctr_key_dump -> Wis;
ctr_key_dump -> WorkInst;
Delays -> Delays;
ECShmem -> ECShmem;
ExtAlloc -> ExtAlloc;
ExtAlloc -> Allocation;
hazslots -> ContainerHelper;
hazslots -> stat;
hazslots -> hazslots;
hideslots -> ContainerHelper;
hideslots -> stat;
hideslots -> hideslots;
json_spirit_reader -> json_spirit_reader;
json_spirit_reader -> json_spirit_value;
json_spirit_value -> json_spirit_value;
json_spirit_writer -> json_spirit_writer;
json_spirit_writer -> json_spirit_value;
Lock -> Lock;
Log -> Log;
main -> Yard;
main -> XMLListener;
main -> yms;
main -> statagg;
main -> alloclistener;
Message -> Message;
Nodes -> Block;
Nodes -> Row;
Nodes -> Nodes;
Nodes -> berths;
oow -> oow;
Oows -> Oows;
OptimizerJob -> OptimizerJob;
OptimizerJobsList -> Yard;
OptimizerJobsList -> OptimizerJobsList;
OptimizerJobsList -> WorkInst;
Parameters -> Parameters;
Params -> Params;
Params -> OptimizerJobsList;
Params -> Block;
Params -> Yard;
Params -> env;
Params -> ContainerNotFoundException;
Params -> VesselNotFoundException;
Params -> Statistics;
Params -> ContainerHelper;
Params -> berths;
reeferbay -> ContainerHelper;
reeferbay -> stat;
reeferbay -> reeferbay;
ReeferRow -> Block;
ReeferRow -> ReeferRow;
ReeferRow -> ContainerNotFoundException;
Row -> Row;
Row -> Block;
Row -> Yard;
Row -> ContainerHelper;
Row -> ContainerNotFoundException;
Row -> stat;
ServerSocket -> ServerSocket;
ServerSocket -> SocketException;
Slot -> Yard;
Slot -> Block;
Slot -> Row;
Slot -> ContainerHelper;
Slot -> ydslot;
Slot -> ContainerNotFoundException;
Slot -> Slot;
Socket -> Socket;
Socket -> SocketException;
statagg -> Block;
statagg -> reeferbay;
statagg -> statagg;
stat -> load_ctr;
stat -> ContainerHelper;
stat -> stat;
Statistics -> Statistics;
Statistics -> Allocation;
Statistics -> ContainerNotFoundException;
Statistics -> VesselNotFoundException;
str_to_time_t -> str_to_time_t;
tier -> tier;
truckArea -> ContainerHelper;
truckArea -> stat;
truckArea -> truckArea;
Vessel -> ContainerHelper;
Vessel -> XMLListener;
Vessel -> Vessel;
Vessels -> ContainerHelper;
Vessels -> XMLListener;
Vessels -> Vessels;
Wis -> Wis;
Wis -> Block;
Wis -> Yard;
WorkInst -> ec;
WorkInst -> ECShmem;
WorkInst -> NullWiException;
WorkInst -> Block;
WorkInst -> XMLListener;
WorkInst -> WorkInst;
XMLListener -> BestAllocsList;
XMLListener -> ContainerNotFoundException;
XMLListener -> Conslist;
XMLListener -> ServerSocket;
XMLListener -> SocketException;
XMLListener -> XMLListener;
XMLListener -> VesselNotFoundException;
XMLListener -> berths;
XMLListener -> truckArea;
XMLListener -> stat;
XMLListener -> oow;
Yardcom -> Yardcom;
Yardcom -> SocketException;
Yard -> yard_shm_daem;
Yard -> cont;
Yard -> Params;
Yard -> Nodes;
Yard -> Vessels;
Yard -> VesselNotFoundException;
Yard -> Yard;
yms -> eclimits;
yms -> SocketException;
yms -> ContainerHelper;
yms -> ContainerNotFoundException;
yms -> YtoHtml;
yms -> yms;
YtoHtml -> Block;
YtoHtml -> Row;
YtoHtml -> Slot;
YtoHtml -> ContainerHelper;
YtoHtml -> YtoHtml;
AllocationFilter -> Wis;
AllocationFilter -> Slot;
AllocationFilter -> Ches;
AllocationFilter -> Yard;
AllocationFilter -> Log;
AllocationFilter -> bannedSlots;
Allocation -> Slot;
alloclistener -> Yard;
alloclistener -> Params;
alloclistener -> yms;
ban -> bannedSlots;
ban -> ContainerHelper;
bannedSlots -> cont;
bannedSlots -> ContainerHelper;
bannedSlots -> Slot;
berths -> concreteObserver;
berths -> concreteSubject;
berths -> stat;
berths -> Nodes;
berths -> Yard;
BestAlloc -> Allocation;
BestAlloc -> Slot;
BestAlloc -> Block;
BestAllocsList -> Consol;
Block -> Slot;
Block -> Row;
Block -> Allocation;
Block -> Params;
Block -> Yard;
Block -> concreteObserver;
Block -> concreteSubject;
Block -> stat;
Block -> reeferbay;
Ches -> ECShmem;
Ches -> Oows;
Ches -> Wis;
Ches -> WorkInst;
ClientSocket -> Socket;
ClientSocket -> Message;
concreteObserver -> cont;
concreteObserver -> observer;
concreteSubject -> cont;
concreteSubject -> subject;
concreteSubject -> concreteObserver;
Conslist -> Consol;
Conslist -> Log;
Conslist -> Wis;
Conslist -> Yardcom;
Conslist -> Statistics;
Consol -> Slot;
Consol -> WorkInst;
Consol -> Allocation;
ContainerHelper -> cont;
ContainerHelper -> Reefer;
ContainerNotFoundException -> Exception;
CostFunction -> Params;
Delays -> Statistics;
ECShmem -> ecipc;
ExtAlloc -> Allocation;
hazslots -> concreteObserver;
hazslots -> stat;
hideslots -> concreteObserver;
hideslots -> stat;
json_spirit -> json_spirit_value;
json_spirit -> json_spirit_reader;
json_spirit -> json_spirit_writer;
json_spirit_reader -> json_spirit_value;
json_spirit_writer -> json_spirit_value;
Nodes -> Row;
Nodes -> Block;
Nodes -> Yard;
NullWiException -> Exception;
observer -> cont;
oow -> BestAllocsList;
oow -> Conslist;
Oows -> ECShmem;
OptimizerJob -> ecipc;
OptimizerJobsList -> OptimizerJob;
OptimizerJobsList -> Yard;
OptimizerJobsList -> Row;
Params -> Slot;
Params -> CostFunction;
Params -> Statistics;
Params -> Wis;
Params -> Ches;
Params -> ContainerHelper;
Params -> Yard;
reeferbay -> concreteObserver;
reeferbay -> concreteSubject;
reeferbay -> stat;
ReeferRow -> Row;
Row -> Slot;
Row -> Block;
Row -> Yard;
Row -> Allocation;
Row -> concreteObserver;
Row -> concreteSubject;
Row -> stat;
Row -> Reefer;
ServerSocket -> Socket;
Slot -> cont;
Slot -> yard_shm_daem;
Slot -> Reefer;
Slot -> concreteSubject;
Slot -> concreteObserver;
Slot -> tier;
Slot -> ban;
SocketException -> Exception;
Socket -> Message;
statagg -> Yard;
stat -> load_ctr;
Statistics -> Row;
Statistics -> Slot;
Statistics -> Yard;
Statistics -> Log;
Statistics -> WorkInst;
subject -> cont;
subject -> concreteObserver;
tier -> concreteSubject;
truckArea -> concreteObserver;
truckArea -> stat;
VesselNotFoundException -> Exception;
Vessels -> yard_shm_daem;
Vessels -> Vessel;
Wis -> ECShmem;
Wis -> Slot;
Wis -> WorkInst;
WorkInst -> ecshm;
WorkInst -> ECShmem;
WorkInst -> NullWiException;
WorkInst -> Slot;
WorkInst -> Row;
XMLListener -> yms;
XMLListener -> Yard;
Yardcom -> ClientSocket;
Yard -> Slot;
Yard -> Block;
Yard -> Allocation;
Yard -> yard_shm_daem;
Yard -> Params;
Yard -> Wis;
Yard -> Ches;
Yard -> Nodes;
Yard -> Vessels;
Yard -> Vessel;
Yard -> concreteObserver;
Yard -> stat;
Yard -> tier;
Yard -> truckArea;
Yard -> berths;
Yard -> hazslots;
Yard -> hideslots;
Yard -> allocationtimes;
yms -> sock;
yms -> tcp_msg;
yms -> Delays;
yms -> Yard;
yms -> Consol;
yms -> wi;
yms -> Statistics;
yms -> Params;
yms -> Parameters;
yms -> Wis;
yms -> Yardcom;
yms -> WorkInst;
yms -> AllocationFilter;
yms -> YtoHtml;
yms -> oow;
yms -> Log;
YtoHtml -> Slot;
YtoHtml -> Yard;
}
dot -Tpng includes.dot -o includes.png