Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Side by Side Diff: libadblockplus-android-settings/src/org/adblockplus/libadblockplus/android/settings/AdblockSettings.java

Issue 29379647: Issue 4948 - add possibility to not send data depending on connection properties (Closed)
Patch Set: updated dependency to binaries, updated comment for allowed connection type Created March 30, 2017, 2:12 p.m.
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * This file is part of Adblock Plus <https://adblockplus.org/>, 2 * This file is part of Adblock Plus <https://adblockplus.org/>,
3 * Copyright (C) 2006-2016 Eyeo GmbH 3 * Copyright (C) 2006-2016 Eyeo GmbH
4 * 4 *
5 * Adblock Plus is free software: you can redistribute it and/or modify 5 * Adblock Plus is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as 6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation. 7 * published by the Free Software Foundation.
8 * 8 *
9 * Adblock Plus is distributed in the hope that it will be useful, 9 * Adblock Plus is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
(...skipping 13 matching lines...) Expand all
24 24
25 /** 25 /**
26 * Adblock settings 26 * Adblock settings
27 */ 27 */
28 public class AdblockSettings implements Serializable 28 public class AdblockSettings implements Serializable
29 { 29 {
30 private transient boolean adblockEnabled; 30 private transient boolean adblockEnabled;
31 private transient Boolean acceptableAdsEnabled; 31 private transient Boolean acceptableAdsEnabled;
32 private List<Subscription> subscriptions; 32 private List<Subscription> subscriptions;
33 private List<String> whitelistedDomains; 33 private List<String> whitelistedDomains;
34 private ConnectionType allowedConnectionType;
34 35
35 public boolean isAdblockEnabled() 36 public boolean isAdblockEnabled()
36 { 37 {
37 return adblockEnabled; 38 return adblockEnabled;
38 } 39 }
39 40
40 public void setAdblockEnabled(boolean adblockEnabled) 41 public void setAdblockEnabled(boolean adblockEnabled)
41 { 42 {
42 this.adblockEnabled = adblockEnabled; 43 this.adblockEnabled = adblockEnabled;
43 } 44 }
(...skipping 21 matching lines...) Expand all
65 public List<String> getWhitelistedDomains() 66 public List<String> getWhitelistedDomains()
66 { 67 {
67 return whitelistedDomains; 68 return whitelistedDomains;
68 } 69 }
69 70
70 public void setWhitelistedDomains(List<String> whitelistedDomains) 71 public void setWhitelistedDomains(List<String> whitelistedDomains)
71 { 72 {
72 this.whitelistedDomains = whitelistedDomains; 73 this.whitelistedDomains = whitelistedDomains;
73 } 74 }
74 75
76 public ConnectionType getAllowedConnectionType()
77 {
78 return allowedConnectionType;
79 }
80
81 public void setAllowedConnectionType(ConnectionType allowedConnectionType)
82 {
83 this.allowedConnectionType = allowedConnectionType;
84 }
85
75 @Override 86 @Override
76 public String toString() 87 public String toString()
77 { 88 {
78 return "AdblockSettings{" + 89 return "AdblockSettings{" +
79 "adblockEnabled=" + adblockEnabled + 90 "adblockEnabled=" + adblockEnabled +
80 ", acceptableAdsEnabled=" + acceptableAdsEnabled + 91 ", acceptableAdsEnabled=" + acceptableAdsEnabled +
81 ", subscriptions:" + (subscriptions != null ? subscriptions.size() : 0) + 92 ", subscriptions:" + (subscriptions != null ? subscriptions.size() : 0) +
82 ", whitelistedDomains:" + (whitelistedDomains != null ? whitelistedDomains .size() : 0) + 93 ", whitelistedDomains:" + (whitelistedDomains != null ? whitelistedDomains .size() : 0) +
94 ", allowedConnectionType=" + (allowedConnectionType != null ? allowedConne ctionType.getValue() : "null") +
83 '}'; 95 '}';
84 } 96 }
85 } 97 }
OLDNEW

Powered by Google App Engine
This is Rietveld