// Copyright 2019 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
//     https://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

package com.google.sps.classes;

import java.util.ArrayList;

// represents the settings of a keyword campaign that can be copied to a DSA campaign
// contains all the necessary information about a keyword campaign, including id, input settings, and statistics
public class KeywordCampaign {

    public int keywordCampaignId;
    public int userId;
    // the id's of all the DSA campaigns associated with this keyword campaign
    public ArrayList<Integer> DSACampaignIds;

    // settings
    public String name;
    public String fromDate;
    public String toDate;
    public double dailyBudget;
    public String location;
    public String domain;
    public String target;

    // statistics
    public int impressions;
    public int clicks;
    public double cost;

    public KeywordCampaign(int keywordCampaignId, int userId, String name, String fromDate, String toDate, double dailyBudget, String location, String domain, String target, int impressions, int clicks, double cost, ArrayList<Integer> DSACampaignIds) {
        this.keywordCampaignId = keywordCampaignId;
        this.userId = userId;
        this.name = name;
        this.fromDate = fromDate;
        this.toDate = toDate;
        this.dailyBudget = dailyBudget;
        this.location = location;
        this.domain = domain;
        this.target = target;
        this.impressions = impressions;
        this.clicks = clicks;
        this.cost = cost;
        this.DSACampaignIds = DSACampaignIds;
    }
}
@@ -651,218 +651,173 @@
 %0A// 
-represents the settings of a keyword campaign that can be copied to a DSA campaign%0A// contains all the necessary information about a keyword campaign, including id, input settings, and statistics%0Apublic class K
+contains all the necessary information about a keyword campaign%0Apublic class KeywordCampaign %7B%0A%0A    // unique identifier for the keyword campaign%0A    public String k
 eywo
@@ -830,34 +830,57 @@
 aign
- %7B%0A
+Id;
 %0A    
-public int
+// id of the user who created the
  keyword
 Camp
@@ -871,35 +871,33 @@
  the keyword
-C
+ c
 ampaign
-Id;
 %0A    public 
@@ -896,19 +896,22 @@
  public 
+Str
 in
-t
+g
  userId;
@@ -1003,39 +1003,38 @@
 ublic ArrayList%3C
-Integer
+String
 %3E DSACampaignIds
@@ -1039,76 +1039,71 @@
 ds;%0A
-%0A
     // 
-settings%0A    public String name;%0A    public String fromDate;
+name of the keyword campaign (used for display purposes)
 %0A   
@@ -1121,196 +1121,370 @@
 ing 
-toDat
+nam
 e;%0A
+%0A
     
-public double dailyBudget;%0A    public String location;%0A    public String domain;%0A    public String target;%0A%0A    // statistics%0A    public int impressions;%0A    public int clicks;
+// statistics used to calculate the uplift of a DSA campaign (e.g. impressions uplift = DSA campaign impressions - keyword campaign impressions)%0A%0A    //  how many times an ad appears on a search result page%0A    public int impressions;%0A    // how many times a user clicks on an ad link%0A    public int clicks;%0A    // total money spent on the ad campaign
 %0A   
@@ -1532,19 +1532,22 @@
 ampaign(
+Str
 in
-t
+g
  keyword
@@ -1558,19 +1558,22 @@
 aignId, 
+Str
 in
-t
+g
  userId,
@@ -1577,118 +1577,53 @@
 Id, 
-String name, String fromDate, String toDate, double dailyBudget, String location, String domain, String target
+ArrayList%3CString%3E DSACampaignIds, String name
 , in
@@ -1664,43 +1664,8 @@
 cost
-, ArrayList%3CInteger%3E DSACampaignIds
 ) %7B%0A
@@ -1763,218 +1763,67 @@
 his.
-name = name;%0A        this.fromDate = fromDate;%0A        this.toDate = toDate;%0A        this.dailyBudget = dailyBudget;%0A        this.location = location;%0A        this.domain = domain;%0A        this.target = target;
+DSACampaignIds = DSACampaignIds;%0A        this.name = name;%0A
 %0A   
@@ -1919,54 +1919,8 @@
 st;%0A
-        this.DSACampaignIds = DSACampaignIds;%0A
     

Update KeywordCampaign.java with new settings, add comments.