Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

//package com.java2s;
//License from project: Open Source License 

import android.content.Context;

import android.widget.Toast;

public class Main {
    /**
     * Shows a toast with the methane level
     *
     * @param methane the methane level
     *
     * @param context the context
     */
    public static void showMethaneToast(Integer methane, Context context) {
        String message = "Methane level: " + Integer.toString(methane);
        Toast.makeText(context, message, Toast.LENGTH_SHORT).show();
    }
}