Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

//package com.java2s;
import android.app.Activity;

import java.lang.ref.WeakReference;
import java.util.ArrayList;
import java.util.List;

public class Main {
    private static List<WeakReference> activitys = new ArrayList<>();

    public static void addActivity(Activity a) {
        activitys.add(new WeakReference(a));
    }
}