BasicFragmentTransition implements FragmentTransition { @Override public void writeToParcel(@NonNull final Parcel dest, final int flags) { dest.writeInt(inAnimRes); dest.writeInt(outAnimRes); dest.writeInt(inBackAnimRes); dest.writeInt(outBackAnimRes); dest.writeString(name); } BasicFragmentTransition(
			@AnimRes @AnimatorRes final int inAnim,
			@AnimRes @AnimatorRes final int outAnim
	);  BasicFragmentTransition(
			@AnimRes @AnimatorRes final int inAnim,
			@AnimRes @AnimatorRes final int outAnim,
			@AnimRes @AnimatorRes final int inBackAnim,
			@AnimRes @AnimatorRes final int outBackAnim
	);  BasicFragmentTransition(
			@AnimRes @AnimatorRes final int inAnim,
			@AnimRes @AnimatorRes final int outAnim,
			@AnimRes @AnimatorRes final int inBackAnim,
			@AnimRes @AnimatorRes final int outBackAnim,
			@NonNull final String name
	); protected  BasicFragmentTransition(@NonNull final Parcel source); @Override void writeToParcel(@NonNull final Parcel dest, final int flags); @Override int describeContents(); @Override @AnimRes @AnimatorRes int getIncomingAnimation(); @Override @AnimRes @AnimatorRes int getOutgoingAnimation(); @Override @AnimRes @AnimatorRes int getIncomingBackStackAnimation(); @Override @AnimRes @AnimatorRes int getOutgoingBackStackAnimation(); @Override @NonNull String getName(); static final Creator<BasicFragmentTransition> CREATOR; }
@Test public void testWriteToParcel() { final int inAnimation = android.R.anim.fade_in; final int inAnimationBack = android.R.anim.fade_out; final int outAnimation = android.R.anim.slide_in_left; final int outAnimationBack = android.R.anim.slide_out_right; final BasicFragmentTransition transition = new BasicFragmentTransition(inAnimation, outAnimation, inAnimationBack, outAnimationBack, "TEST_TRANSITION"); final Parcel parcel = Parcel.obtain(); transition.writeToParcel(parcel, 0); parcel.setDataPosition(0); assertThat(parcel.readInt(), is(inAnimation)); assertThat(parcel.readInt(), is(outAnimation)); assertThat(parcel.readInt(), is(inAnimationBack)); assertThat(parcel.readInt(), is(outAnimationBack)); assertThat(parcel.readString(), is("TEST_TRANSITION")); parcel.recycle(); }