Add list duplication lambdas

This commit is contained in:
NMerz
2020-11-15 17:18:30 -05:00
parent 1fe04e038b
commit 27f0d74422
4 changed files with 123 additions and 0 deletions

View File

@@ -17,6 +17,7 @@ import androidx.navigation.ui.AppBarConfiguration;
import androidx.navigation.ui.NavigationUI;
import com.amplifyframework.auth.AuthException;
import com.example.listify.data.List;
import com.example.listify.data.ListDuplicate;
import com.example.listify.data.ListReposition;
import com.example.listify.data.SearchHistory;
import com.example.listify.ui.LoginPage;
@@ -110,6 +111,7 @@ public class MainActivity extends AppCompatActivity implements CreateListDialogF
try {
System.out.println(historyReceiver.await());
requestor.putObject(new ListReposition(291, 1));
requestor.postObject(new ListDuplicate(290, "yet another list"));
} catch (Exception e) {
e.printStackTrace();
}

View File

@@ -0,0 +1,37 @@
package com.example.listify.data;
// Info on List to copy
public class ListDuplicate {
Integer listID;
String name;
public ListDuplicate(Integer listID, String name) {
this.listID = listID;
this.name = name;
}
@Override
public String toString() {
return "ListDuplicate{" +
"listID=" + listID +
", name='" + name + '\'' +
'}';
}
public Integer getListID() {
return listID;
}
public void setListID(Integer listID) {
this.listID = listID;
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
}