패스트캠퍼스 챌린지

[패스트캠퍼스 챌린지 12일차] Android push 알람 앱

FireBase를 이용하여서 어플 이용자에게 push알림을 보내고 받아보는 기능을 구현할 예정입니다.

오늘은 이 어플의 기본 UI를 구성해 보았습니다.

<TextView
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:text="결과"
        android:textColor="@color/black"
        android:textSize="20sp"
        android:textStyle="bold" />

    <TextView
        android:id="@+id/resultTextView"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_margin="12dp"
        android:layout_marginStart="4dp"
        android:textSize="16sp"
        tools:text="결과 값 입니다.." />

    <TextView
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_marginTop="30dp"
        android:text="FireBaseToken"
        android:textColor="@color/black"
        android:textSize="20sp"
        android:textStyle="bold" />

    <TextView
        android:id="@+id/fireBaseTokenTextView"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_margin="12dp"
        android:layout_marginStart="4dp"
        android:text="Loading..."
        android:textIsSelectable="true"
        android:textSize="16sp" />

복잡하지 않은 구조여서 Constraint 구조가 아닌 LinearLayout에 orientation을 vertical 속성을 주어 구성하였습니다.

private val resultTextView: TextView by lazy {
        findViewById(R.id.resultTextView)
    }
private val fireBaseTokenTextView: TextView by lazy {
      	findViewById(R.id.fireBaseTokenTextView)
    }

패스트캠퍼스 바로가기 -> https://bit.ly/3FVdhDa

본 포스팅은 패스트캠퍼스 환급 챌린지 참여를 위해 작성되었습니다.