다음을 통해 공유


FragmentTransaction.Attach(Fragment) Method

Definition

Re-attach a fragment after it had previously been detached from the UI with #detach(Fragment).

[Android.Runtime.Register("attach", "(Landroid/app/Fragment;)Landroid/app/FragmentTransaction;", "GetAttach_Landroid_app_Fragment_Handler")]
public abstract Android.App.FragmentTransaction? Attach (Android.App.Fragment? fragment);
[<Android.Runtime.Register("attach", "(Landroid/app/Fragment;)Landroid/app/FragmentTransaction;", "GetAttach_Landroid_app_Fragment_Handler")>]
abstract member Attach : Android.App.Fragment -> Android.App.FragmentTransaction

Parameters

fragment
Fragment

The fragment to be attached.

Returns

Returns the same FragmentTransaction instance.

Attributes

Remarks

Re-attach a fragment after it had previously been detached from the UI with #detach(Fragment). This causes its view hierarchy to be re-created, attached to the UI, and displayed.

Java documentation for android.app.FragmentTransaction.attach(android.app.Fragment).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to