Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

//package com.java2s;

import android.util.Log;
import java.io.UnsupportedEncodingException;

import java.net.URLEncoder;

public class Main {
    private static final String TAG = "wiki_leaps";

    public static String encodeUnicodeString(String source) {
        try {
            source = URLEncoder.encode(source, "UTF-8");
        } catch (UnsupportedEncodingException e) {
            Log.e(TAG, e.getMessage());
            e.printStackTrace();
        }
        return source;
    }
}