comp.lang.ada
 help / color / mirror / Atom feed
* Help with project
@ 1999-04-18  0:00 bob
  1999-04-19  0:00 ` Stephen Leake
  0 siblings, 1 reply; 3+ messages in thread
From: bob @ 1999-04-18  0:00 UTC (permalink / raw)


Hi, I am having a problem in trying to implement a program that
simulates
a waiting line queue in an airport, the workers are stored in an array
of
records, (the record will be the agent), each agent has a pointer to
their
line(type line_access),
			

I must declare a record for a customer in the generic spec , and
instantiate it in our source code, inside this record will be info
about
the customer(time in queue, etc),
now, below in the private area, I have
 PRIVATE
  TYPE line;
  TYPE line_access IS ACCESS line; 
  TYPE line IS RECORD 
        info: X;
        Next: line_access;      
  END RECORD;

TYPE Agent IS RECORD
      	Head:line_access;
          cur_cust:line_access;
          free_time:Integer;
	   etc(things for the agent)     
END RECORD;

where X is the customer record which will instantiated
the problem is, i have subprograms in the source that wont compile
because
i cant access agent or any of its fields, unless i go through the
spec.
some of the subprograms are , checkagents-see if they are done
servicing
cur_cust
addtoqueue-adds a cust
removefromqueue-removes from head of link list, assigns that one to
cur_cust

if i put the subprograms to the body, then it cant find the fields for
the
customer
do u have any ideas what to do?

thanks for taking the time to read this
jarrod

Please reply to....

rossjar@db.erau.edu






^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~1999-04-20  0:00 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1999-04-18  0:00 Help with project bob
1999-04-19  0:00 ` Stephen Leake
1999-04-20  0:00   ` Ehud Lamm

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox