I need this in Mobile Aplications. this all is same question okay please hurry up and thank you !!
You are about to develop an application for job postings and job applicants searching for jobs. This question contains 4 parts. Follow the indications and read the given code in order to complete the missing parts. The MySQL database is called androidfinal and it contains two tables: job and applicant. Jescription location salary Sold wie JOD job_id 10.6 y clean 3.19 in Clear wane age email tield phone gender Applicant applicant_id 11 . Aju has . The application contains three activities: MainActivity, Jobs activity, and JobDetails activity, as shown below. AR wit OR C Men vi Cloudy Part 1: The MainActivity The main activity of the app looks like the below image along with their XML IDs. It contains fields for the applicant to create a profile. When the user fills the fields and presses on create account, he/she is taken to the Jobs activity showing all the available jobs in the database. The components 1. aplicar po Component Tree ConstraintLayout Ab namefield Plain Text) spinner the agefield Plain Text An emailfield Plain Text Ab phonefield Plain Text) button "Create account button2 "Post a job radioGroup vertical fernale Female O male Male PopliconEmail GREATE A PETAR The spinner contains: engineering, business, pharmacy and arts. 1.1) Write the code for the "post a job" button such that, when clicked, it takes us to an activity called "NewJobActivity". Assume there's onclick="newjob" added to the xml of this button. public void newjob(view v){ Intent i = . } 1.2) Fill in the code for the activity so that when the user fills the fields and presses on "create account", a) a new tuple is added to the applicant table in the database, and b) the user is navigated to the Jobs activity Assume there's a PHP file called createaccount.php that adds the tuple to the database and returns the ID of the newly added tuple as shown below. PHP court re nosotropheco to the site Sen bundle GPT) 7 WA... fi.de fumtied, well, it Asy Sony - tertinto please, told, s, phone, gender, wel nor, ...) myys quartienn. ) che_uct_id ! NAVY public class MainActivity extends AppCompatActivity { Edit Text namefield agefield, emailfield phonefield; Spinners RadioButton rfrm protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout activity_main); Toolbar toolbar = findViewById(R.id.toolbar); setSupportActionBartoolbar); namefield = findViewById(R.id.namefield); agefield = findViewById(R.id.agefield); emailfield = findViewById(R.id.emailfield); phonefield = findViewById(R.id phonefield), s = findViewById(R.id.spinner): rf = findViewById(R.id.female); rm = findViewById(R.id.male). } public void createaccount(View v){ String n,a,ep.f.g; n = : a = e = ; p = ; fa : if X g="f"; } else { g="m" } String url = "http://10.0.2.2/androidfinal/createaccount.php?"; url + ; RequestQueue queue = StringRequest request = new StringRequest(Request.Method.GET, url, new Response. Listener
({ public void onResponse(String response) { ; }}, new Response. ErrorListener() { public void on Error Response(VolleyError error) { Toast.makeText(getApplicationContext(). "Error:" + error.toString, Toast.LENGTH_SHORT).show(); }}); :}} Part 2: The Custom adapter Assume we create an xml file called row.xml that represents each item of the listview. D Description Location Salary Field Component Tree ConstraintLayout A jobid Ab Jabdesc"Description Ab Jobloc "Location Al jobsalary Salary jobfield-Feld details IDs of the components. Note that details is an imageButton row.mi Complete the code of the custom adapter such that: The listview is filled with data from the job table in the database that are available through the jsonarray. The description of the job only shows 30 characters of it followed by three dots (...) When the user presses on the arrow, he/she is navigated to the jobDetails activity taking the job ID to it so we can use it there to retrieve all the details of the clicked job. Jobs 1 > Arduino and raspberry pi exper... Tripoli 1000 engineering 2 > Software developer needed, jav. Beirut 1200 engineering 3 3 Marketing and advertising need.. Beirut 900 business Assume there's a PHP file called getalljobs that returns the json array as shown below. PHP gallob.php sho Joon_encodireturn_ATTAYIT 23 Context con JSOArray data Layout Inflater inflater; istrator public Custor Adapter Contest , SONArray data this.con this.data-data; inflater - Layout Inflater c.getSystemservace context. LAYOUT INFLATER SERVICES public class Holder i TextView Jobatu. Jo desctv, jo salarytu, jabfieldtv.obloctv, Inage Button detalisbutton But loc View piwiwist, Vi vich, Virap vi vores final Holder Holder - Holder that vin rouw; row salater, intato. Layout.row, nati: et les cher folder.jbidt - icw.finity II K. id., bid! older.jobdesctv powinVieyti. 13. Joldescil Holder.blarte radicatindVie dydi. 18. Jabentary holder tal de VI. Find 10. d. fofeld Selainetails! toldur-jolactv 150bject abs - Sata.opt 2011 try{ //fill the data from the json array holder.jobidtv.setText( String description = String shortdescription = description.substring(0,30) +".", holder.jobdesctv.setText(shortdescription); holder.jobsalarytv.setText( holder.jobfieldtv.setText( holder.jobloctv.setText( // program the click of the arrow button to go to jobdetails activity and take the id of the clicked job with us holder detailsbutton.setTag( holder.detailsbutton. (new View.OnClickListener { @Override public void onClick(View v) { Intent intent = intent.putExtra('job_id", holder detailsbutton.getTagO+""); con.startActivity (intent); catch (JSONException e) { Toast.makeText(con,e.toString(. Toast.LENGTH_SHORT).show();} return rowView:}} Part3: The Jobs activity. 3.1) Fill in the code such that the listview is initialized and filled from the database. Don't forget that there's a php file called getalljobs mentioned in question 2 that is available. When the floating button is clicked, the user is navigated to "NewJobActivity". public class soba stands descono activity LIV list: JSOUrray data; Custonadapter cust_adapters protected void onCreatarunde avenstanceStatel setContentVtIH. 1ayout activity Jobs Floatingtonbutton Fab Finds byrdi. 1d. fab) tab.ston tekist new Vinu.OnClickListener) Derride public void onClick(View view) list - findViewById(R.id. is tudowa getdatatrando ) public void getdatatrodo 11 String url = RequestQueue queur - Volley.nevequestuene(this) JoonArrayequest sonArraycat new sonArrayRequest Risponos.Listuneisuutta, Film Ourri public void onfe spansel JSONArray response) Till code: data = response, cust_adapater = Part4: The Job Details activity Remember that when the user presses the arrow next to any item in the listview, he/she is navigated to the job Details activity holding the ID of the job. 4 5:47 Job Details 1 Arduino and raspberry pi expert needed for security systems. 1000$/month Tripoli engineering www.techtop.com The layout IDs are shown below: Component Tree O Constraint Layout Ab jobid - "TextView" Ab jobdescription - "TextVi... Ab jobsalary-"TextView" Ab joblocation - "TextView" Ab jobfield - "TextView" Ab jobwebsite- "TextView" A A A A Fill in the codes to program the following: . Fill the full details of the job in the layout. If the user clicks on the location, the google maps open showing the location. . If the user clicks on the website, the web browser opens showing the website. Assume a php file called getJobByld is available and returns a json array with 1 json object only corresponding to the job tuple. PHP getjobb roquire_once connection.php' $job id = $_GET['111'11 Sretan_array Array() $get job - "select from job where Job_id-'s job_Id" Sresult - wyqli_queryScon, Sget job): Srous myell Coto (Sult) Array_puche Sreten_array, SON: echo con encodeSreten_array 7 JAVA Job Details public class Job Details extends AppCompatActivity TextView jobsd, jobdescription, obsalary, job location, jobfield, obwebsite; Override protected void onCreate(Bundle savedInstanceStatel super.onCreate anved InstanceState) setContentViewIR.layout.activity_job_details: Joelde fundvityIdiR.id. Jabfield jobide findViewById(R.id. Jobad) jobdescriptione findViewById(R.id.febdescription johsalary findViewById(R. 1d. Johsatary job : tindViewById(R.id. ..brasiteli Intent i getintent(); Requestqunue queue - Volley.neRequestueue (this); JsonArrayRequest sonArrayRequest = new JsonArrayRequest (Request.Method.GET, url. null, new Response.Listener final Uri web = ("http://"+ jobwebsite.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View view) { startActivity (new Intent/ .);} }); final Uri loc = Uri.parse(" joblocation.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View view) { startActivity(new Intent .)); } catch(JSONException e) { }new Response. ErrorListener() { @Override public void onErrorResponse(VolleyError error) { Toast.makeText(getApplicationContext("Error:"+error.toString().Toast.LENGTH_LONG).showO:}}) queue.add(jsonArray Request); }} You are about to develop an application for job postings and job applicants searching for jobs. This question contains 4 parts. Follow the indications and read the given code in order to complete the missing parts. The MySQL database is called androidfinal and it contains two tables: job and applicant. Jescription location salary Sold wie JOD job_id 10.6 y clean 3.19 in Clear wane age email tield phone gender Applicant applicant_id 11 . Aju has . The application contains three activities: MainActivity, Jobs activity, and JobDetails activity, as shown below. AR wit OR C Men vi Cloudy Part 1: The MainActivity The main activity of the app looks like the below image along with their XML IDs. It contains fields for the applicant to create a profile. When the user fills the fields and presses on create account, he/she is taken to the Jobs activity showing all the available jobs in the database. The components 1. aplicar po Component Tree ConstraintLayout Ab namefield Plain Text) spinner the agefield Plain Text An emailfield Plain Text Ab phonefield Plain Text) button "Create account button2 "Post a job radioGroup vertical fernale Female O male Male PopliconEmail GREATE A PETAR The spinner contains: engineering, business, pharmacy and arts. 1.1) Write the code for the "post a job" button such that, when clicked, it takes us to an activity called "NewJobActivity". Assume there's onclick="newjob" added to the xml of this button. public void newjob(view v){ Intent i = . } 1.2) Fill in the code for the activity so that when the user fills the fields and presses on "create account", a) a new tuple is added to the applicant table in the database, and b) the user is navigated to the Jobs activity Assume there's a PHP file called createaccount.php that adds the tuple to the database and returns the ID of the newly added tuple as shown below. PHP court re nosotropheco to the site Sen bundle GPT) 7 WA... fi.de fumtied, well, it Asy Sony - tertinto please, told, s, phone, gender, wel nor, ...) myys quartienn. ) che_uct_id ! NAVY public class MainActivity extends AppCompatActivity { Edit Text namefield agefield, emailfield phonefield; Spinners RadioButton rfrm protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout activity_main); Toolbar toolbar = findViewById(R.id.toolbar); setSupportActionBartoolbar); namefield = findViewById(R.id.namefield); agefield = findViewById(R.id.agefield); emailfield = findViewById(R.id.emailfield); phonefield = findViewById(R.id phonefield), s = findViewById(R.id.spinner): rf = findViewById(R.id.female); rm = findViewById(R.id.male). } public void createaccount(View v){ String n,a,ep.f.g; n = : a = e = ; p = ; fa : if X g="f"; } else { g="m" } String url = "http://10.0.2.2/androidfinal/createaccount.php?"; url + ; RequestQueue queue = StringRequest request = new StringRequest(Request.Method.GET, url, new Response. Listener({ public void onResponse(String response) { ; }}, new Response. ErrorListener() { public void on Error Response(VolleyError error) { Toast.makeText(getApplicationContext(). "Error:" + error.toString, Toast.LENGTH_SHORT).show(); }}); :}} Part 2: The Custom adapter Assume we create an xml file called row.xml that represents each item of the listview. D Description Location Salary Field Component Tree ConstraintLayout A jobid Ab Jabdesc"Description Ab Jobloc "Location Al jobsalary Salary jobfield-Feld details IDs of the components. Note that details is an imageButton row.mi Complete the code of the custom adapter such that: The listview is filled with data from the job table in the database that are available through the jsonarray. The description of the job only shows 30 characters of it followed by three dots (...) When the user presses on the arrow, he/she is navigated to the jobDetails activity taking the job ID to it so we can use it there to retrieve all the details of the clicked job. Jobs 1 > Arduino and raspberry pi exper... Tripoli 1000 engineering 2 > Software developer needed, jav. Beirut 1200 engineering 3 3 Marketing and advertising need.. Beirut 900 business Assume there's a PHP file called getalljobs that returns the json array as shown below. PHP gallob.php sho Joon_encodireturn_ATTAYIT 23 Context con JSOArray data Layout Inflater inflater; istrator public Custor Adapter Contest , SONArray data this.con this.data-data; inflater - Layout Inflater c.getSystemservace context. LAYOUT INFLATER SERVICES public class Holder i TextView Jobatu. Jo desctv, jo salarytu, jabfieldtv.obloctv, Inage Button detalisbutton But loc View piwiwist, Vi vich, Virap vi vores final Holder Holder - Holder that vin rouw; row salater, intato. Layout.row, nati: et les cher folder.jbidt - icw.finity II K. id., bid! older.jobdesctv powinVieyti. 13. Joldescil Holder.blarte radicatindVie dydi. 18. Jabentary holder tal de VI. Find 10. d. fofeld Selainetails! toldur-jolactv 150bject abs - Sata.opt 2011 try{ //fill the data from the json array holder.jobidtv.setText( String description = String shortdescription = description.substring(0,30) +".", holder.jobdesctv.setText(shortdescription); holder.jobsalarytv.setText( holder.jobfieldtv.setText( holder.jobloctv.setText( // program the click of the arrow button to go to jobdetails activity and take the id of the clicked job with us holder detailsbutton.setTag( holder.detailsbutton. (new View.OnClickListener { @Override public void onClick(View v) { Intent intent = intent.putExtra('job_id", holder detailsbutton.getTagO+""); con.startActivity (intent); catch (JSONException e) { Toast.makeText(con,e.toString(. Toast.LENGTH_SHORT).show();} return rowView:}} Part3: The Jobs activity. 3.1) Fill in the code such that the listview is initialized and filled from the database. Don't forget that there's a php file called getalljobs mentioned in question 2 that is available. When the floating button is clicked, the user is navigated to "NewJobActivity". public class soba stands descono activity LIV list: JSOUrray data; Custonadapter cust_adapters protected void onCreatarunde avenstanceStatel setContentVtIH. 1ayout activity Jobs Floatingtonbutton Fab Finds byrdi. 1d. fab) tab.ston tekist new Vinu.OnClickListener) Derride public void onClick(View view) list - findViewById(R.id. is tudowa getdatatrando ) public void getdatatrodo 11 String url = RequestQueue queur - Volley.nevequestuene(this) JoonArrayequest sonArraycat new sonArrayRequest Risponos.Listuneisuutta, Film Ourri public void onfe spansel JSONArray response) Till code: data = response, cust_adapater = Part4: The Job Details activity Remember that when the user presses the arrow next to any item in the listview, he/she is navigated to the job Details activity holding the ID of the job. 4 5:47 Job Details 1 Arduino and raspberry pi expert needed for security systems. 1000$/month Tripoli engineering www.techtop.com The layout IDs are shown below: Component Tree O Constraint Layout Ab jobid - "TextView" Ab jobdescription - "TextVi... Ab jobsalary-"TextView" Ab joblocation - "TextView" Ab jobfield - "TextView" Ab jobwebsite- "TextView" A A A A Fill in the codes to program the following: . Fill the full details of the job in the layout. If the user clicks on the location, the google maps open showing the location. . If the user clicks on the website, the web browser opens showing the website. Assume a php file called getJobByld is available and returns a json array with 1 json object only corresponding to the job tuple. PHP getjobb roquire_once connection.php' $job id = $_GET['111'11 Sretan_array Array() $get job - "select from job where Job_id-'s job_Id" Sresult - wyqli_queryScon, Sget job): Srous myell Coto (Sult) Array_puche Sreten_array, SON: echo con encodeSreten_array 7 JAVA Job Details public class Job Details extends AppCompatActivity TextView jobsd, jobdescription, obsalary, job location, jobfield, obwebsite; Override protected void onCreate(Bundle savedInstanceStatel super.onCreate anved InstanceState) setContentViewIR.layout.activity_job_details: Joelde fundvityIdiR.id. Jabfield jobide findViewById(R.id. Jobad) jobdescriptione findViewById(R.id.febdescription johsalary findViewById(R. 1d. Johsatary job : tindViewById(R.id. ..brasiteli Intent i getintent(); Requestqunue queue - Volley.neRequestueue (this); JsonArrayRequest sonArrayRequest = new JsonArrayRequest (Request.Method.GET, url. null, new Response.Listener final Uri web = ("http://"+ jobwebsite.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View view) { startActivity (new Intent/ .);} }); final Uri loc = Uri.parse(" joblocation.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View view) { startActivity(new Intent .)); } catch(JSONException e) { }new Response. ErrorListener() { @Override public void onErrorResponse(VolleyError error) { Toast.makeText(getApplicationContext("Error:"+error.toString().Toast.LENGTH_LONG).showO:}}) queue.add(jsonArray Request); }}