{"id":37081,"date":"2024-11-01T09:54:42","date_gmt":"2024-11-01T09:54:42","guid":{"rendered":"http:\/\/atmokpo.com\/w\/?p=37081"},"modified":"2024-11-01T11:42:19","modified_gmt":"2024-11-01T11:42:19","slug":"kotlin-android-app-development-course-fragment-view-that-acts-like-an-activity","status":"publish","type":"post","link":"https:\/\/atmokpo.com\/w\/37081\/","title":{"rendered":"kotlin android app development course, fragment &#8211; view that acts like an activity"},"content":{"rendered":"<p><body><\/p>\n<p>In Android app development, a fragment is a very important component. Fragments are modules that make up part of the user interface (UI) and can manage their own lifecycle independently. By using fragments, you can transition between different screens and create reusable UI components. This tutorial will explore how to utilize fragments using Kotlin in detail.<\/p>\n<h2>The Concept of Fragments<\/h2>\n<p>A fragment is a component that includes a small part of the UI within an activity. An activity represents a single screen that interacts with the user, but various fragments can be used to compose multiple UIs within a single activity. Fragments are very useful for the following reasons:<\/p>\n<ul>\n<li>Reusable: The same fragment can be used in various activities.<\/li>\n<li>Modular: Specific parts of the UI can be created as separate classes.<\/li>\n<li>Flexibility: They can be added, removed, or replaced dynamically based on screen size and orientation.<\/li>\n<\/ul>\n<h2>The Lifecycle of Fragments<\/h2>\n<p>Fragments have their own lifecycle. The lifecycle of a fragment depends on the activity, but lifecycle methods are called independently. The main lifecycle methods of a fragment include:<\/p>\n<ul>\n<li><code>onAttach()<\/code>: Called when the fragment is attached to the activity.<\/li>\n<li><code>onCreate()<\/code>: Called to perform initialization tasks for the fragment.<\/li>\n<li><code>onCreateView()<\/code>: Called to create the UI for the fragment.<\/li>\n<li><code>onActivityCreated()<\/code>: Called after the activity&#8217;s creation is complete.<\/li>\n<li><code>onStart()<\/code>: Called when the fragment starts becoming visible to the user.<\/li>\n<li><code>onResume()<\/code>: Called when the fragment is interacting with the user.<\/li>\n<li><code>onPause()<\/code>: Called when the fragment stops interacting with the user.<\/li>\n<li><code>onStop()<\/code>: Called when the fragment is no longer visible to the user.<\/li>\n<li><code>onDestroyView()<\/code>: Called when the fragment&#8217;s UI is destroyed.<\/li>\n<li><code>onDetach()<\/code>: Called when the fragment is detached from the activity.<\/li>\n<\/ul>\n<h2>Creating a Basic Fragment<\/h2>\n<p>Now, let&#8217;s create a simple fragment using Kotlin. Start a new project and follow the steps below.<\/p>\n<h3>1. Create a Fragment Class<\/h3>\n<p>Create a Kotlin class for the fragment that inherits from <code>Fragment<\/code>. For example, let&#8217;s create a fragment named <code>SampleFragment<\/code>:<\/p>\n<pre><code>package com.example.myapp\n\nimport android.os.Bundle\nimport android.view.LayoutInflater\nimport android.view.View\nimport android.view.ViewGroup\nimport androidx.fragment.app.Fragment\n\nclass SampleFragment : Fragment() {\n\n    override fun onCreateView(\n        inflater: LayoutInflater, \n        container: ViewGroup?, \n        savedInstanceState: Bundle?\n    ): View? {\n        \/\/ Inflate the layout file to be used in the fragment.\n        return inflater.inflate(R.layout.fragment_sample, container, false)\n    }\n}<\/code><\/pre>\n<h3>2. Create a Layout File<\/h3>\n<p>Create a layout XML file used by the fragment. Write the <code>res\/layout\/fragment_sample.xml<\/code> file as follows:<\/p>\n<pre><code>&lt;?xml version=\"1.0\" encoding=\"utf-8\"?&gt;\n&lt;LinearLayout xmlns:android=\"http:\/\/schemas.android.com\/apk\/res\/android\"\n    android:layout_width=\"match_parent\"\n    android:layout_height=\"match_parent\"\n    android:orientation=\"vertical\"&gt;\n\n    &lt;TextView\n        android:id=\"@+id\/sampleTextView\"\n        android:layout_width=\"wrap_content\"\n        android:layout_height=\"wrap_content\"\n        android:text=\"Hello, Fragment!\" \/&gt;\n\n&lt;\/LinearLayout&gt;<\/code><\/pre>\n<h3>3. Use the Fragment in an Activity<\/h3>\n<p>Now the created fragment is ready to be used in an activity. Add a <code>FrameLayout<\/code> to the activity&#8217;s layout file to create space for the fragment:<\/p>\n<pre><code>&lt;?xml version=\"1.0\" encoding=\"utf-8\"?&gt;\n&lt;LinearLayout xmlns:android=\"http:\/\/schemas.android.com\/apk\/res\/android\"\n    android:layout_width=\"match_parent\"\n    android:layout_height=\"match_parent\"\n    android:orientation=\"vertical\"&gt;\n\n    &lt;FrameLayout\n        android:id=\"@+id\/fragment_container\"\n        android:layout_width=\"match_parent\"\n        android:layout_height=\"match_parent\"\/&gt;\n\n&lt;\/LinearLayout&gt;<\/code><\/pre>\n<h3>4. Add the Fragment to the Activity<\/h3>\n<p>In the activity&#8217;s <code>onCreate<\/code> method, dynamically add the fragment:<\/p>\n<pre><code>package com.example.myapp\n\nimport android.os.Bundle\nimport androidx.appcompat.app.AppCompatActivity\nimport androidx.fragment.app.FragmentManager\n\nclass MainActivity : AppCompatActivity() {\n\n    override fun onCreate(savedInstanceState: Bundle?) {\n        super.onCreate(savedInstanceState)\n        setContentView(R.layout.activity_main)\n\n        \/\/ Add the Fragment using FragmentManager.\n        if (savedInstanceState == null) {\n            val fragment = SampleFragment()\n            supportFragmentManager.beginTransaction()\n                .add(R.id.fragment_container, fragment)\n                .commit()\n        }\n    }\n}<\/code><\/pre>\n<h2>Switching Between Fragments<\/h2>\n<p>Now let&#8217;s create multiple fragments and learn how to switch between them. As a simple example, we will implement a feature that switches to another fragment when a button is clicked.<\/p>\n<h3>1. Create a Second Fragment<\/h3>\n<p>Create a second fragment named <code>SecondFragment<\/code> and add a layout that includes a button:<\/p>\n<pre><code>package com.example.myapp\n\nimport android.os.Bundle\nimport android.view.LayoutInflater\nimport android.view.View\nimport android.view.ViewGroup\nimport androidx.fragment.app.Fragment\nimport kotlinx.android.synthetic.main.fragment_second.*\n\nclass SecondFragment : Fragment() {\n\n    override fun onCreateView(\n        inflater: LayoutInflater, \n        container: ViewGroup?, \n        savedInstanceState: Bundle?\n    ): View? {\n        return inflater.inflate(R.layout.fragment_second, container, false)\n    }\n\n    override fun onViewCreated(view: View, savedInstanceState: Bundle?) {\n        super.onViewCreated(view, savedInstanceState)\n\n        \/\/ Switch the fragment on button click.\n        button.setOnClickListener {\n            val firstFragment = SampleFragment()\n            fragmentManager?.beginTransaction()\n                ?.replace(R.id.fragment_container, firstFragment)\n                ?.addToBackStack(null)\n                ?.commit()\n        }\n    }\n}<\/code><\/pre>\n<h3>2. Create a Layout File for the Second Fragment<\/h3>\n<p>Create the layout file for the second fragment as follows:<\/p>\n<pre><code>&lt;?xml version=\"1.0\" encoding=\"utf-8\"?&gt;\n&lt;LinearLayout xmlns:android=\"http:\/\/schemas.android.com\/apk\/res\/android\"\n    android:layout_width=\"match_parent\"\n    android:layout_height=\"match_parent\"\n    android:orientation=\"vertical\"&gt;\n\n    &lt;Button\n        android:id=\"@+id\/button\"\n        android:layout_width=\"wrap_content\"\n        android:layout_height=\"wrap_content\"\n        android:text=\"Back to Sample Fragment\"\/&gt;\n\n&lt;\/LinearLayout&gt;<\/code><\/pre>\n<h3>3. Add Fragment Switching<\/h3>\n<p>In the existing <code>SampleFragment<\/code>, add a method for switching to the second fragment when a button is clicked:<\/p>\n<pre><code>class SampleFragment : Fragment() {\n    \/\/ omitted...\n\n    override fun onViewCreated(view: View, savedInstanceState: Bundle?) {\n        super.onViewCreated(view, savedInstanceState)\n\n        \/\/ Switch to the second fragment on button click.\n        val button = view.findViewById<button>(R.id.sampleButton)\n        button.setOnClickListener {\n            val secondFragment = SecondFragment()\n            fragmentManager?.beginTransaction()\n                ?.replace(R.id.fragment_container, secondFragment)\n                ?.addToBackStack(null)\n                ?.commit()\n        }\n    }\n}<\/button><\/code><\/pre>\n<h2>Sending Data and Using Collections<\/h2>\n<p>Let&#8217;s learn how to transfer data between fragments and use collections. A common way to pass data to a fragment is by using a <code>Bundle<\/code>. In the example below, we will take user input for a search term and use it to create a new fragment.<\/p>\n<h3>1. Add EditText for User Input<\/h3>\n<pre><code>&lt;LinearLayout\n    xmlns:android=\"http:\/\/schemas.android.com\/apk\/res\/android\"\n    android:layout_width=\"match_parent\"\n    android:layout_height=\"match_parent\"\n    android:orientation=\"vertical\"&gt;\n\n    &lt;EditText\n        android:id=\"@+id\/searchEditText\"\n        android:layout_width=\"match_parent\"\n        android:layout_height=\"wrap_content\"\n        android:hint=\"Enter search term\"\/&gt;\n\n    &lt;Button\n        android:id=\"@+id\/searchButton\"\n        android:layout_width=\"wrap_content\"\n        android:layout_height=\"wrap_content\"\n        android:text=\"Search\"\/&gt;\n\n&lt;\/LinearLayout&gt;<\/code><\/pre>\n<h3>2. Write a Method to Pass the Search Term<\/h3>\n<p>Write a method to take the keyword input and pass it to the second fragment:<\/p>\n<pre><code>searchButton.setOnClickListener {\n    val keyword = searchEditText.text.toString()\n    val searchFragment = SearchFragment()\n    \n    \/\/ Use Bundle to pass data\n    val bundle = Bundle()\n    bundle.putString(\"keyword\", keyword)\n    searchFragment.arguments = bundle\n    \n    \/\/ Fragment switch\n    fragmentManager?.beginTransaction()\n        ?.replace(R.id.fragment_container, searchFragment)\n        ?.addToBackStack(null)\n        ?.commit()\n}<\/code><\/pre>\n<h3>3. Receive and Display the Data<\/h3>\n<p>Receive and display the data passed in <code>SearchFragment<\/code>:<\/p>\n<pre><code>class SearchFragment : Fragment() {\n\n    override fun onCreateView(\n        inflater: LayoutInflater, \n        container: ViewGroup?, \n        savedInstanceState: Bundle?\n    ): View? {\n        return inflater.inflate(R.layout.fragment_search, container, false)\n    }\n\n    override fun onViewCreated(view: View, savedInstanceState: Bundle?) {\n        super.onViewCreated(view, savedInstanceState)\n\n        \/\/ Receive data from Bundle\n        val keyword = arguments?.getString(\"keyword\")\n\n        \/\/ Display data\n        val textView = view.findViewById<textview>(R.id.resultTextView)\n        textView.text = if (keyword != null) \"Search term: $keyword\" else \"No search term entered.\"\n    }\n}<\/textview><\/code><\/pre>\n<h2>Managing Data with ViewModel and Fragments<\/h2>\n<p>Let&#8217;s learn how to manage data in fragments using ViewModel. ViewModel is a class that can store and manage UI-related data in activities and fragments, and is useful for maintaining data according to the lifecycle.<\/p>\n<h3>1. Create a ViewModel Class<\/h3>\n<pre><code>import androidx.lifecycle.MutableLiveData\nimport androidx.lifecycle.ViewModel\n\nclass MyViewModel : ViewModel() {\n    val data: MutableLiveData<string> = MutableLiveData()\n}<\/string><\/code><\/pre>\n<h3>2. Use ViewModel in the Fragment<\/h3>\n<p>Show how to create a ViewModel in the fragment and observe data to update the UI:<\/p>\n<pre><code>import androidx.fragment.app.activityViewModels\n\nclass SampleFragment : Fragment() {\n    private val viewModel: MyViewModel by activityViewModels()\n\n    override fun onViewCreated(view: View, savedInstanceState: Bundle?) {\n        super.onViewCreated(view, savedInstanceState)\n\n        \/\/ Observe data from ViewModel\n        viewModel.data.observe(viewLifecycleOwner) { newData -&gt;\n            \/\/ Update UI\n            textView.text = newData\n        }\n\n        \/\/ Change data to update UI\n        button.setOnClickListener {\n            viewModel.data.value = \"New data\"\n        }\n    }\n}<\/code><\/pre>\n<h2>Navigation with Fragments<\/h2>\n<p>Using the Android Navigation component, you can more easily manage transitions between fragments. The Navigation component simplifies transitions between fragments and activities.<\/p>\n<h3>1. Set Up Navigation Graph<\/h3>\n<p>Create a navigation graph and add fragments. Define transitions between fragments in the graph. This definition helps reduce code complexity and automatically handles transition animations and back stack management.<\/p>\n<h3>2. Switch Fragments Using Navigation Architecture<\/h3>\n<pre><code>val navHostFragment = supportFragmentManager\n        .findFragmentById(R.id.nav_host_fragment) as NavHostFragment\n    val navController = navHostFragment.navController\n\n    \/\/ Switch fragments on button click\n    button.setOnClickListener {\n        navController.navigate(R.id.action_sampleFragment_to_secondFragment)\n    }<\/code><\/pre>\n<h2>Conclusion<\/h2>\n<p>In this tutorial, we learned about the concept and usage of fragments in Android app development. Fragments allow us to structure the UI in a reusable and modular manner while managing lifecycles, transferring data, and leveraging ViewModels for data management. Using the navigation component makes switching between fragments easier. Based on this knowledge, try applying these concepts in real projects.<\/p>\n<h2>References<\/h2>\n<ul>\n<li>Android Official Documentation: <a href=\"https:\/\/developer.android.com\/guide\/fragments\">Fragments<\/a><\/li>\n<li>Android Navigation Guide: <a href=\"https:\/\/developer.android.com\/guide\/navigation\">Navigation Guide<\/a><\/li>\n<li>Kotlin Official Documentation: <a href=\"https:\/\/kotlinlang.org\/docs\/home.html\">Kotlin Documentation<\/a><\/li>\n<\/ul>\n<p><\/body><\/p>\n","protected":false},"excerpt":{"rendered":"<p>In Android app development, a fragment is a very important component. Fragments are modules that make up part of the user interface (UI) and can manage their own lifecycle independently. By using fragments, you can transition between different screens and create reusable UI components. This tutorial will explore how to utilize fragments using Kotlin in &hellip; <a href=\"https:\/\/atmokpo.com\/w\/37081\/\" class=\"more-link\">\ub354 \ubcf4\uae30<span class=\"screen-reader-text\"> &#8220;kotlin android app development course, fragment &#8211; view that acts like an activity&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[143],"tags":[],"class_list":["post-37081","post","type-post","status-publish","format-standard","hentry","category-kotlin-android-app-development"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v26.2 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>kotlin android app development course, fragment - view that acts like an activity - \ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/atmokpo.com\/w\/37081\/\" \/>\n<meta property=\"og:locale\" content=\"ko_KR\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"kotlin android app development course, fragment - view that acts like an activity - \ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8\" \/>\n<meta property=\"og:description\" content=\"In Android app development, a fragment is a very important component. Fragments are modules that make up part of the user interface (UI) and can manage their own lifecycle independently. By using fragments, you can transition between different screens and create reusable UI components. This tutorial will explore how to utilize fragments using Kotlin in &hellip; \ub354 \ubcf4\uae30 &quot;kotlin android app development course, fragment &#8211; view that acts like an activity&quot;\" \/>\n<meta property=\"og:url\" content=\"https:\/\/atmokpo.com\/w\/37081\/\" \/>\n<meta property=\"og:site_name\" content=\"\ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8\" \/>\n<meta property=\"article:published_time\" content=\"2024-11-01T09:54:42+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2024-11-01T11:42:19+00:00\" \/>\n<meta name=\"author\" content=\"root\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@bebubo4\" \/>\n<meta name=\"twitter:site\" content=\"@bebubo4\" \/>\n<meta name=\"twitter:label1\" content=\"\uae00\uc4f4\uc774\" \/>\n\t<meta name=\"twitter:data1\" content=\"root\" \/>\n\t<meta name=\"twitter:label2\" content=\"\uc608\uc0c1 \ub418\ub294 \ud310\ub3c5 \uc2dc\uac04\" \/>\n\t<meta name=\"twitter:data2\" content=\"7\ubd84\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/atmokpo.com\/w\/37081\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/atmokpo.com\/w\/37081\/\"},\"author\":{\"name\":\"root\",\"@id\":\"https:\/\/atmokpo.com\/w\/#\/schema\/person\/91b6b3b138fbba0efb4ae64b1abd81d7\"},\"headline\":\"kotlin android app development course, fragment &#8211; view that acts like an activity\",\"datePublished\":\"2024-11-01T09:54:42+00:00\",\"dateModified\":\"2024-11-01T11:42:19+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/atmokpo.com\/w\/37081\/\"},\"wordCount\":776,\"publisher\":{\"@id\":\"https:\/\/atmokpo.com\/w\/#organization\"},\"articleSection\":[\"Kotlin Android app development\"],\"inLanguage\":\"ko-KR\"},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/atmokpo.com\/w\/37081\/\",\"url\":\"https:\/\/atmokpo.com\/w\/37081\/\",\"name\":\"kotlin android app development course, fragment - view that acts like an activity - \ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8\",\"isPartOf\":{\"@id\":\"https:\/\/atmokpo.com\/w\/#website\"},\"datePublished\":\"2024-11-01T09:54:42+00:00\",\"dateModified\":\"2024-11-01T11:42:19+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/atmokpo.com\/w\/37081\/#breadcrumb\"},\"inLanguage\":\"ko-KR\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/atmokpo.com\/w\/37081\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/atmokpo.com\/w\/37081\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\ud648\",\"item\":\"https:\/\/atmokpo.com\/w\/en\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"kotlin android app development course, fragment &#8211; view that acts like an activity\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/atmokpo.com\/w\/#website\",\"url\":\"https:\/\/atmokpo.com\/w\/\",\"name\":\"\ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8\",\"description\":\"\",\"publisher\":{\"@id\":\"https:\/\/atmokpo.com\/w\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/atmokpo.com\/w\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"ko-KR\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/atmokpo.com\/w\/#organization\",\"name\":\"\ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8\",\"url\":\"https:\/\/atmokpo.com\/w\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"ko-KR\",\"@id\":\"https:\/\/atmokpo.com\/w\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/atmokpo.com\/w\/wp-content\/uploads\/2024\/11\/logo.png\",\"contentUrl\":\"https:\/\/atmokpo.com\/w\/wp-content\/uploads\/2024\/11\/logo.png\",\"width\":400,\"height\":400,\"caption\":\"\ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8\"},\"image\":{\"@id\":\"https:\/\/atmokpo.com\/w\/#\/schema\/logo\/image\/\"},\"sameAs\":[\"https:\/\/x.com\/bebubo4\"]},{\"@type\":\"Person\",\"@id\":\"https:\/\/atmokpo.com\/w\/#\/schema\/person\/91b6b3b138fbba0efb4ae64b1abd81d7\",\"name\":\"root\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"ko-KR\",\"@id\":\"https:\/\/atmokpo.com\/w\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/708197b41fc6435a7ce22d951b25d4a47e9e904270cb1f04682d4f025066f80c?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/708197b41fc6435a7ce22d951b25d4a47e9e904270cb1f04682d4f025066f80c?s=96&d=mm&r=g\",\"caption\":\"root\"},\"sameAs\":[\"http:\/\/atmokpo.com\/w\"],\"url\":\"https:\/\/atmokpo.com\/w\/author\/root\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"kotlin android app development course, fragment - view that acts like an activity - \ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/atmokpo.com\/w\/37081\/","og_locale":"ko_KR","og_type":"article","og_title":"kotlin android app development course, fragment - view that acts like an activity - \ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8","og_description":"In Android app development, a fragment is a very important component. Fragments are modules that make up part of the user interface (UI) and can manage their own lifecycle independently. By using fragments, you can transition between different screens and create reusable UI components. This tutorial will explore how to utilize fragments using Kotlin in &hellip; \ub354 \ubcf4\uae30 \"kotlin android app development course, fragment &#8211; view that acts like an activity\"","og_url":"https:\/\/atmokpo.com\/w\/37081\/","og_site_name":"\ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8","article_published_time":"2024-11-01T09:54:42+00:00","article_modified_time":"2024-11-01T11:42:19+00:00","author":"root","twitter_card":"summary_large_image","twitter_creator":"@bebubo4","twitter_site":"@bebubo4","twitter_misc":{"\uae00\uc4f4\uc774":"root","\uc608\uc0c1 \ub418\ub294 \ud310\ub3c5 \uc2dc\uac04":"7\ubd84"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/atmokpo.com\/w\/37081\/#article","isPartOf":{"@id":"https:\/\/atmokpo.com\/w\/37081\/"},"author":{"name":"root","@id":"https:\/\/atmokpo.com\/w\/#\/schema\/person\/91b6b3b138fbba0efb4ae64b1abd81d7"},"headline":"kotlin android app development course, fragment &#8211; view that acts like an activity","datePublished":"2024-11-01T09:54:42+00:00","dateModified":"2024-11-01T11:42:19+00:00","mainEntityOfPage":{"@id":"https:\/\/atmokpo.com\/w\/37081\/"},"wordCount":776,"publisher":{"@id":"https:\/\/atmokpo.com\/w\/#organization"},"articleSection":["Kotlin Android app development"],"inLanguage":"ko-KR"},{"@type":"WebPage","@id":"https:\/\/atmokpo.com\/w\/37081\/","url":"https:\/\/atmokpo.com\/w\/37081\/","name":"kotlin android app development course, fragment - view that acts like an activity - \ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8","isPartOf":{"@id":"https:\/\/atmokpo.com\/w\/#website"},"datePublished":"2024-11-01T09:54:42+00:00","dateModified":"2024-11-01T11:42:19+00:00","breadcrumb":{"@id":"https:\/\/atmokpo.com\/w\/37081\/#breadcrumb"},"inLanguage":"ko-KR","potentialAction":[{"@type":"ReadAction","target":["https:\/\/atmokpo.com\/w\/37081\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/atmokpo.com\/w\/37081\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\ud648","item":"https:\/\/atmokpo.com\/w\/en\/"},{"@type":"ListItem","position":2,"name":"kotlin android app development course, fragment &#8211; view that acts like an activity"}]},{"@type":"WebSite","@id":"https:\/\/atmokpo.com\/w\/#website","url":"https:\/\/atmokpo.com\/w\/","name":"\ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8","description":"","publisher":{"@id":"https:\/\/atmokpo.com\/w\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/atmokpo.com\/w\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"ko-KR"},{"@type":"Organization","@id":"https:\/\/atmokpo.com\/w\/#organization","name":"\ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8","url":"https:\/\/atmokpo.com\/w\/","logo":{"@type":"ImageObject","inLanguage":"ko-KR","@id":"https:\/\/atmokpo.com\/w\/#\/schema\/logo\/image\/","url":"https:\/\/atmokpo.com\/w\/wp-content\/uploads\/2024\/11\/logo.png","contentUrl":"https:\/\/atmokpo.com\/w\/wp-content\/uploads\/2024\/11\/logo.png","width":400,"height":400,"caption":"\ub77c\uc774\ube0c\uc2a4\ub9c8\ud2b8"},"image":{"@id":"https:\/\/atmokpo.com\/w\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/x.com\/bebubo4"]},{"@type":"Person","@id":"https:\/\/atmokpo.com\/w\/#\/schema\/person\/91b6b3b138fbba0efb4ae64b1abd81d7","name":"root","image":{"@type":"ImageObject","inLanguage":"ko-KR","@id":"https:\/\/atmokpo.com\/w\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/708197b41fc6435a7ce22d951b25d4a47e9e904270cb1f04682d4f025066f80c?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/708197b41fc6435a7ce22d951b25d4a47e9e904270cb1f04682d4f025066f80c?s=96&d=mm&r=g","caption":"root"},"sameAs":["http:\/\/atmokpo.com\/w"],"url":"https:\/\/atmokpo.com\/w\/author\/root\/"}]}},"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack-related-posts":[],"_links":{"self":[{"href":"https:\/\/atmokpo.com\/w\/wp-json\/wp\/v2\/posts\/37081","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/atmokpo.com\/w\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/atmokpo.com\/w\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/atmokpo.com\/w\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/atmokpo.com\/w\/wp-json\/wp\/v2\/comments?post=37081"}],"version-history":[{"count":1,"href":"https:\/\/atmokpo.com\/w\/wp-json\/wp\/v2\/posts\/37081\/revisions"}],"predecessor-version":[{"id":37082,"href":"https:\/\/atmokpo.com\/w\/wp-json\/wp\/v2\/posts\/37081\/revisions\/37082"}],"wp:attachment":[{"href":"https:\/\/atmokpo.com\/w\/wp-json\/wp\/v2\/media?parent=37081"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/atmokpo.com\/w\/wp-json\/wp\/v2\/categories?post=37081"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/atmokpo.com\/w\/wp-json\/wp\/v2\/tags?post=37081"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}