package com.tsgame.tsgame_niuniu.util;


import com.tsgame.tsgame_niuniu.system.Myapplication;

import android.content.pm.PackageInfo;
import android.content.pm.PackageManager.NameNotFoundException;

public class getAppinfo {
	public static String getAppVersionName() {
		PackageInfo packageInfo;
		try {
			packageInfo = Myapplication.application.getPackageManager()
					.getPackageInfo(Myapplication.application.getPackageName(),
							0);
			return packageInfo.versionName;
		} catch (NameNotFoundException e) {
			e.printStackTrace();
		}
		return "1.0";
	}
	public static int getAppVersioncode() {
		PackageInfo packageInfo;
		try {
			packageInfo = Myapplication.application.getPackageManager().getPackageInfo(Myapplication.application.getPackageName(),0);
			return packageInfo.versionCode;
		} catch (NameNotFoundException e) {
			e.printStackTrace();
		}
		return 1;
	}
	public static String getAppos() {

		return "ANDROID";
	}

	public static Long getTimeStamp() {

		return System.currentTimeMillis();
	}

	public static String getSign() {

		return "";
	}

}
