[add] 1.添加接口服务类 2.添加网络请求类 3.UI呈现类添加部分赋值内容
This commit is contained in:
@@ -10,7 +10,7 @@ import androidx.annotation.NonNull;
|
||||
import androidx.annotation.Nullable;
|
||||
import androidx.constraintlayout.widget.ConstraintLayout;
|
||||
|
||||
import com.mogo.eagle.core.data.notice.NoticeInfo;
|
||||
import com.mogo.eagle.core.data.notice.NoticeTrafficInfo;
|
||||
import com.mogo.eagle.core.function.hmi.R;
|
||||
|
||||
/**
|
||||
@@ -61,7 +61,7 @@ public class NoticeBannerView extends ConstraintLayout {
|
||||
}
|
||||
|
||||
//数据改变刷新UI
|
||||
public void pushBeanChanged(NoticeInfo info){
|
||||
public void pushBeanChanged(NoticeTrafficInfo info){
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -9,15 +9,20 @@ import android.widget.TextView;
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.recyclerview.widget.RecyclerView;
|
||||
|
||||
import com.mogo.eagle.core.data.notice.NoticeValue;
|
||||
import com.mogo.eagle.core.function.hmi.R;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author liujing
|
||||
* @description 描述
|
||||
* @description 事故详情(事故来源等)呈现
|
||||
* @since: 10/26/21
|
||||
*/
|
||||
class NoticeTrafficAdapter extends RecyclerView.Adapter {
|
||||
LayoutInflater mLayoutInflater;
|
||||
private List<NoticeValue> data = new ArrayList();
|
||||
|
||||
public NoticeTrafficAdapter(@NonNull Context context) {
|
||||
mLayoutInflater = LayoutInflater.from(context);
|
||||
@@ -34,7 +39,9 @@ class NoticeTrafficAdapter extends RecyclerView.Adapter {
|
||||
|
||||
@Override
|
||||
public void onBindViewHolder(@NonNull RecyclerView.ViewHolder holder, int position) {
|
||||
|
||||
NoticeValue value = data.get(position);
|
||||
((TrafficInfoHolder) holder).keyText.setText(value.getKey());
|
||||
((TrafficInfoHolder) holder).valueText.setText(value.getValue());
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
Reference in New Issue
Block a user