Welcome, guest! Login / Register - Why register?
Psst.. new poll here.
Psst.. new forums here.
Microsoft is blocking us again (TY IP Reputation!) so just use oauth login instead. :)

Paste

Pasted as Java by galibimtiaz ( 7 years ago )
package com.example.myapplication;


import android.os.Bundle;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.TextView;

import androidx.fragment.app.Fragment;


/**
 * A simple {@link Fragment} subclass.
 */
public class BlankFragment extends Fragment implements TestInterface {

    TextView fragmentTvId;
    
    @Override
    public View onCreateView(LayoutInflater inflater, ViewGroup container,
                             Bundle savedInstanceState) {

        // Inflate the layout for this fragment
        View view = inflater.inflate(R.layout.fragment_blank, container, false);

        fragmentTvId = view.findViewById(R.id.fragmentTvId);
        return view;
    }

    @Override
    public void setVal(String value) {
        fragmentTvId.setText(value);
    }
}

 

Revise this Paste

Parent: 100817
Your Name: Code Language: