Skip to content

Commit 2096d04

Browse files
committed
Minimize users feature scope. First attempt.
1 parent 8c0a7ae commit 2096d04

File tree

3 files changed

+16
-17
lines changed

3 files changed

+16
-17
lines changed

app/src/main/java/com/fernandocejas/android10/sample/app/users/CloudUserDataStore.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@
1515
*/
1616
package com.fernandocejas.android10.sample.app.users;
1717

18-
import com.fernandocejas.android10.sample.app.users.cache.UserCache;
1918
import com.fernandocejas.android10.sample.app.data.RestApi;
19+
import com.fernandocejas.android10.sample.app.users.cache.UserCache;
2020
import java.util.List;
2121
import rx.Observable;
2222
import rx.functions.Action1;

app/src/main/java/com/fernandocejas/android10/sample/app/users/User.java

+13-13
Original file line numberDiff line numberDiff line change
@@ -18,11 +18,11 @@
1818
/**
1919
* Class that represents a User in the domain layer.
2020
*/
21-
public class User {
21+
class User {
2222

2323
private final int userId;
2424

25-
public User(int userId) {
25+
User(int userId) {
2626
this.userId = userId;
2727
}
2828

@@ -32,47 +32,47 @@ public User(int userId) {
3232
private String description;
3333
private int followers;
3434

35-
public int getUserId() {
35+
int getUserId() {
3636
return userId;
3737
}
3838

39-
public String getCoverUrl() {
39+
String getCoverUrl() {
4040
return coverUrl;
4141
}
4242

43-
public void setCoverUrl(String coverUrl) {
43+
void setCoverUrl(String coverUrl) {
4444
this.coverUrl = coverUrl;
4545
}
4646

47-
public String getFullName() {
47+
String getFullName() {
4848
return fullName;
4949
}
5050

51-
public void setFullName(String fullName) {
51+
void setFullName(String fullName) {
5252
this.fullName = fullName;
5353
}
5454

55-
public String getEmail() {
55+
String getEmail() {
5656
return email;
5757
}
5858

59-
public void setEmail(String email) {
59+
void setEmail(String email) {
6060
this.email = email;
6161
}
6262

63-
public String getDescription() {
63+
String getDescription() {
6464
return description;
6565
}
6666

67-
public void setDescription(String description) {
67+
void setDescription(String description) {
6868
this.description = description;
6969
}
7070

71-
public int getFollowers() {
71+
int getFollowers() {
7272
return followers;
7373
}
7474

75-
public void setFollowers(int followers) {
75+
void setFollowers(int followers) {
7676
this.followers = followers;
7777
}
7878

app/src/main/java/com/fernandocejas/android10/sample/app/users/UserDataStore.java

+2-3
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
* you may not use this file except in compliance with the License.
66
* You may obtain a copy of the License at
77
*
8-
* http://www.apache.org/licenses/LICENSE-2.0
8+
* http://www.apache.org/licenses/LICENSE-2.0
99
*
1010
* Unless required by applicable law or agreed to in writing, software
1111
* distributed under the License is distributed on an "AS IS" BASIS,
@@ -15,14 +15,13 @@
1515
*/
1616
package com.fernandocejas.android10.sample.app.users;
1717

18-
import com.fernandocejas.android10.sample.app.users.UserEntity;
1918
import java.util.List;
2019
import rx.Observable;
2120

2221
/**
2322
* Interface that represents a data store from where data is retrieved.
2423
*/
25-
public interface UserDataStore {
24+
interface UserDataStore {
2625
/**
2726
* Get an {@link rx.Observable} which will emit a List of {@link UserEntity}.
2827
*/

0 commit comments

Comments
 (0)