Java Project-This project consists of two parts.

1- Re:Servlet,JSP,JSTl,and connect to my SQL"I will provide the codes and example"
2- some topics about core java including cloning and collections topics.
3- examples about core java to applied in eclipse:
Shallow Cloning
Deep Cloning

Important Points about Cloning
1. The object to be cloned must implements Clonable interface. When the Object class finds that the object to be cloned is not an instance of a class that implements Cloneable interface, it throws CloneNotSupportedException.
2. If a class wants to allow clients to clone it's instances, it must override Object's clone method with a public modifier.
3.Other way to implement deep cloning is Serialization
4. When to do shallow copy and deep copy?

Its very simple that if the object has only primitive fields and reference of immutable objects, then obviously you will go for shallow copy but if the object has references to other objects, then based on the requiement, shallow copy or deep copy should be chosen. What I mean here is, if the references are not modified anytime, then there is no point in going for deep copy. You can just opt shallow copy. But if the references are modified often, then you need to go for deep copy. Again there is no hard and fast rule, it all depends on the requirement.

Mobile ,Mobile sort and tree set demo files are related

Solution PreviewSolution Preview

These solutions may offer step-by-step problem-solving explanations or good writing examples that include modern styles of formatting and construction of bibliographies out of text citations and references. Students may use these solutions for personal skill-building and practice. Unethical use is strictly forbidden.

package com.coreexample;

import java.util.Iterator;
import java.util.TreeSet;

public class Person implements Cloneable, Comparable<Person>{

private String name;

private String designation;

private float salary;

public Person(String name, String designation, float salary) { = name;
this.designation = designation;
this.salary = salary;

public String getName() {
return name;

public void setName(String name) { = name;

public String getDesignation() {
return designation;

public void setDesignation(String designation) {
this.designation = designation;

public float getSalary() {
return salary;

public void setSalary(float salary) {
this.salary = salary;

By purchasing this solution you'll be able to access the following files:

for this solution

PayPal, G Pay, ApplePay, Amazon Pay, and all major credit cards accepted.

Find A Tutor

View available Java Programming Tutors

Get College Homework Help.

Are you sure you don't want to upload any files?

Fast tutor response requires as much info as possible.

Upload a file
Continue without uploading

We couldn't find that subject.
Please select the best match from the list below.

We'll send you an email right away. If it's not in your inbox, check your spam folder.

  • 1
  • 2
  • 3
Live Chats