I am using earthquake API when I fetch time of earthquake it is not in Human readable as shown below.
Time in API is in Long form and I want to display it in listview as 00/00/0000
This is how I fetch time and some more data from API :
    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);
        l=(ListView)findViewById(R.id.list_id);
        queue= Volley.newRequestQueue(this);
        request();
        l.setOnItemClickListener(new AdapterView.OnItemClickListener() {
              @Override
              public void onItemClick(AdapterView<?> parent, View view, int position, long id) {
              ApiClass apiClass=list.get(position);
               Uri uri=Uri.parse(apiClass.getUrl());
               Intent intent=new Intent(Intent.ACTION_VIEW,uri);
               startActivity(intent);
              }
          });
    }
                   @Override
                   public void onResponse(String response) {
                       try {
                           JSONObject ob1=new JSONObject(response);
                           JSONArray ob2=ob1.getJSONArray("features");
                           for (int i=0;i<ob2.length();i++){
                               JSONObject ob3=ob2.getJSONObject(i);
                               JSONObject ob4=ob3.getJSONObject("properties");
                               String title=ob4.getString("title");
                               Double mag=ob4.getDouble("mag");
                               Long time=ob4.getLong("time");
                               String u=ob4.getString("url");
                               list.add(new ApiClass(title,mag,time,u));
                           }
                           CustomAdapter adapter=new CustomAdapter(MainActivity.this,list);
                           l.setAdapter(adapter);
                       }
                       catch (JSONException e) {
                           e.printStackTrace();
                       }
                       // Display the first 500 characters of the response string.
                   }
               }, new Response.ErrorListener() {
           @Override
               public void onErrorResponse(VolleyError error) {
               Toast.makeText(MainActivity.this,"Error",Toast.LENGTH_SHORT).show();
           }
       });
       queue.add(stringRequest);
     }
}
Following is my custom adapter java class:
    @Override
    public View getView(int position, @Nullable View convertView, @NonNull ViewGroup parent) {
        View v=convertView;
           if(convertView==null){
               v= LayoutInflater.from(c).inflate(R.layout.custom_layout,parent,false);
           }
           ApiClass ob=(ApiClass) arrayList.get(position);
        CircleImageView image=v.findViewById(R.id.image_id);
        TextView tv1=v.findViewById(R.id.title_id);
        TextView tv2=v.findViewById(R.id.magnitude_id);
        TextView tv3=v.findViewById(R.id.time_id);
        tv1.setText(ob.getTitle().toString());
        tv2.setText(ob.getMag().toString());
        tv3.setText(ob.getTime().toString());
        image.setImageResource(R.drawable.mouse);
        return v;
    }
This is my Apiclass which return value to set value in listview:
    public ApiClass(String title, Double mag, Long time, String url) {
        this.title = title;
        this.mag = mag;
        this.time = time;
        this.url = url;
    }
    public String getTitle() {
        return title;
    }
    public Double getMag() {
        return mag;
    }
    public Long getTime() {
        return  time;
    }
    public String getUrl() {
        return url;
    }
}
 
     
     
    