Example usage for android.support.v4.app Fragment hashCode

List of usage examples for android.support.v4.app Fragment hashCode

Introduction

In this page you can find the example usage for android.support.v4.app Fragment hashCode.

Prototype

@HotSpotIntrinsicCandidate
public native int hashCode();

Source Link

Document

Returns a hash code value for the object.

Usage

From source file:com.uprayzner.mediator.activities.EventActivity.java

public void addFragment(@IdRes int container, Fragment fragment) {
    getSupportFragmentManager().beginTransaction().add(container, fragment)
            .addToBackStack(fragment.hashCode() + "").commitAllowingStateLoss();
}

From source file:com.uprayzner.mediator.activities.EventActivity.java

public void share(Fragment des, View sharedView, @StringRes int transitionName) {
    getSupportFragmentManager().beginTransaction().add(ContentActivity.FRAGMENT_CONTAINER, des)
            .addToBackStack(des.hashCode() + "").addSharedElement(sharedView, getString(transitionName))
            .commit();//from  w  w  w .  j a v  a2  s.  c om
}