public void addLinkedlist1(int data1) { if (current_address1 == null) { current_address1 = new data1(); first_address1 = current_address1; current_address1.set_data2(data1); } else { current_address1.set_nextaddress1(); moveData1 = current_address1; current_address1 = current_address1.get_nextaddress1(); current_address1.set_prevaddress1(moveData1); current_address1.set_data2(data1); } datasize1++; }
public void replaceLinkedlist1(int index1, int data1) { data1 list1 = findLink1(index1); list1.set_data2(data1); }