Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

PLEASE TYPE IT IN JAVA FOR BOTH 4 AND 5 IF POSSIBLE, THANK YOU. 4. Create a class to represent a Process Control Block. For

PLEASE TYPE IT IN JAVA FOR BOTH 4 AND 5 IF POSSIBLE, THANK YOU.

image text in transcribed

4. Create a class to represent a Process Control Block. For now, the control block should only contain the PID and the process status. 5. Create a JAVA interface to allow operations on processes. (Right click, new Java Class and then select interface in IntelliJ) The interface should declare the following methods of the API: int createProcess ( ) throws Exception Creates a process (by creating its process control block) and adds it to the ready queue. Returns the PID of the process created. Throws exception if unable to create the process (for example if no PID are available) void terminateProcess (int pid) throws Exception Terminates the process with the specified pid. Throws exception if the process doesn't exist

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

SQL Antipatterns Avoiding The Pitfalls Of Database Programming

Authors: Bill Karwin

1st Edition

1680508989, 978-1680508987

More Books

Students also viewed these Databases questions

Question

CL I P COL Astro- L(1-cas0) Lsing *A=2 L sin(0/2)

Answered: 1 week ago

Question

What is the preferred personality?

Answered: 1 week ago

Question

What is the relationship between humans?

Answered: 1 week ago