You are on page 1of 38

2013214332

2013-01

() Kavita()

2017 5 31

2013214332

2013-01

() Kavita()

2017 5 31

................................................................. 1
ABSTRACT .............................................................. 2
1 ............................................................. 3
1.1 .............................................. 3
1.2 .................................... 4
1.3 ............................ 8
2 ............................................... 9
2.1 iOS ........................................................... 9
2.2 Windows Phone ................................................ 10
2.3 Android ...................................................... 11
2.4 ..................................................... 13
3 .......................... 14
3.1 ..................................................... 14
3.2 ........................................... 16
3.3 ................................... 17
3.4 Promocode ............................................... 18
3.5 ................................................... 19
3.6 ................................... 20
3.7 ................................................... 21
3.8 ..................................................... 22
4 ................................................. 24
4.1 GCM ID ............................................ 24
4.2 ..................................................... 25
4.3 ................................................... 25
4.4 ........................................... 27
4.5 ........................................... 28
5 .......................................................... 30
............................................................... 32
............................................................ 33



7


IndianMesh Pvt.

,
Android

Android ,

Android

Freight resource integration system


development based on mobile internet
Abstract The Internet created the economic myth. We are thinking: a
country's ability to innovate, and ultimately the country's grasp of
the innovative technology in the market competition in the
performance. The market is the main measure of the value of
innovation, and enterprises should be the main embodiment of
national innovation. By extension, if the 700 million mobile phone
users such a consumer group to establish a platform to make it
widely used in business, business and rural areas, will it create a
miracle? And how much social impact will an application give when
it based on the thinking of mobile Internet development and
operation?
The project is based on a major project in my internship company in
India. Therefore, this paper will start from the economic background
of the Indian market. First, it will analyzes the current mobile device
operating system and compares it, and make a conclusions that
Android will be the best platform to release applications in Indian.
Then combined with the company's multiple needs survey and
specification, the design ideas, including the passenger-side and
driver-side, then use the design ideas on the Android platform, and
finally implement the function for truck network, to integrate the
current Indian market in a variety of freight resources.
Keywords: Resource integration; Android development; the Indian market;
Car Online Booking

1.1


2006 10 2015 206
10.7

1.1

1.2

100
31%

2012
9 2013 15
2014 10

1.2.1

Uber Uber Rush

Uber Rush
[1]
2014 4 Uber Uber Rush

Uber CEO
Uber Uber Rush Uber Eats
20

1.2.2

2015 O2O 4188.5 O2O



O2O
350

APP
APP

1.1

1.1

1.2.3



(Mahindra &Mahindra)
Trringo
400 700 40 70
Trringo (Call Center)
90%


1.1
2014 5

""
1 13 GDP 11%
2
3IT

1.2

1.2


1000 GDP
7.5%
" IT
"
1.3

1.3

1.3


C
200 [2]


AndroidiOS
Windows Phone

2.1 iOS

2.1.1

2007 1 9 2007 Macworld iOS


iPhone OS 6 29 iOS iOS iTunes
iOS 5 OTAOn the Air
iOS iTunes
iOS 5 iCloud [3] WWDC 2013
iOS 7
iPhone iOS 2008
iPhone OS 2010 6 iOS

2.1.2

iOS 12.1% Android


[4]
88% 2016 6 13 2016
iOS 10 2016 9 3 [5]

2.1.3

iOS iPhoneiPod Touch iPad iOS iPod


ClassiciPod Nano iPod Shuffle iTunes iTunes Store
[6]
API API
Objective-CCC++ iPhone OS Webkit JavaScript

CC+Objective-C API
API[7]
iOS iOS :
iOS WebKit Safari
Google ChromeMozilla Firefox Opera
iOS Safari
[8]
iOS iOS H.264
AAC VP9 Opus

iOS
iPhone iPhone [9]

2.2 Windows Phone

2.2.1

Windows Phone WPWindows Phone


Xbox Live Xbox Music
Metro UI Modern
Windows Phone 7 Windows Mobile
Windows Phone 7 2014 10 24
Windows Phone 8.1 2017 7 11 [10]

2.2.2

Twitter Lumia Windows Phone 8


Windows 10 Mobile[11][12] [13]
Windows Phone 8 Windows 10 Mobile
[14]
Windows 10 2015 12 2016 3

10

18 18 NOKIA Lumia 929


Windows Phone [15] [16]

2.2.3

Windows Phone
Windows 10
WP8.1
11

Windows Phone
Windows Phone 10%
Windows Phone

Windows Phone Windows Phone

2.3 Android

2.3.1

Android Linux

Google Open Handset AllianceOHA

Android Andy Rubin

Android 2005
7 11 Google 2007 11 Google 84
Android
Google Apache Android
Android Android Android

11

2.3.2

2010 Android
Symbian[16] [17]
[17]
2014 Google I/O Google 30 10
2013 6 5.38 [18]
2017 3 Android Microsoft Windows
[19]

2.3.3

Android 2010
8 Android
Trojan-SMS.AndroidOS.FakePlayer.a [20]
Android
Android

Google Google Play

Android
2010 8
97%70% 47%[21]

2.3.4

80% Android


Android Android

12

Android

Android


10
Android

2.4

2.4 iOSWindows PhoneAndroid

iOS Windows Phone Android

120 24.5 120

2.4 Windows Phone


Windows Phone

iOS
Android

13

3.1

3.1.1

Android
Android


Google Cloud Messaging GCM

GCM

3.1

3.1

14

GCM GCM

C/S
3.2

3.2

3.1.2

http
respond GCM

15

3.2


GCM GCM
3.2


3.3

POST
POST
GCM
API GCM GCM
GCM ID

GCM ID
GCM ID
GCM ID GCM ID GCM
GCM ID

3.3

16



Direction
Direction

3.4

3.4 Promocode

Promocode
Promocode

17

Promocode Promocode
1Promocode
Promocode

2 Promocode
3 Promocode Promocode

4 Promocode

5

3.5




3.4

3.5 E-R

18



3.1

UID UID

GCM ID String GCM ID

Phone String

Email String

Password Password

Name String

Status Int

Location Geo

Rate Float

Balance Float

3.2

UID UID

Name String

Phone String

Email String

Password Password

GCM ID String GCM ID

Balance Float

Rate Float


3.3

19

UID UID

Orig String

Dest String

Fee Float -1

UserID String UID

DriverID String UID

Status Int

Time Date

3.4 Promocode

UID UID Promocode

City String Promocode

Code String Promocode

ExpiredDate Date Promocode

3.4 PromocodeUsed

UID UID

Code String Promocode

UserID String Code ID

3.6

20

3.6

3.6

0.5%

3.7

Java

3.7 Java

21

3.7


1
2 Java C++.so
3 .so
4 .so
C++.so

3.8


Android
Uber
Android 4.4 3.7

22


3.7

3.8





3.8

23

4.1 GCM ID

GCM ID GCM ID

gcm API
@TargetApi(Build.VERSION_CODES.GINGERBREAD)
public class RegistrationIntentService extends IntentService{}


@TargetApi(Build.VERSION_CODES.GINGERBREAD)
@Override
protected void onHandleIntent(Intent intent) {

try {
synchronized (TAG) {
InstanceID instanceID = InstanceID.getInstance(getApplicationContext());
String token = instanceID.getToken("42490150531",
GoogleCloudMessaging.INSTANCE_ID_SCOPE, null);
Log.i(TAG, "GCM Registration Token: " + token);
// TODO: Implement this method to send any registration to your app's servers.
sendRegistrationToServer(token);
subscribeTopics(token);
}
} catch (Exception e) {
Log.d(TAG, "Failed to complete token refresh", e);

}
Intent registrationComplete = new Intent(SharedPreferenceskeys.REGISTRATION_COMPLETE);
LocalBroadcastManager.getInstance(this).sendBroadcast(registrationComplete);
}

GCM ID Intent
InstanceID
ID instanceID getToken token
Token GCM ID
ID ID GCM ID
ID

24

4.2

POST
API URL
constants URLs
public final static String baseUrl =
"http://minkme.org/outsource/footprint/api/";
// Login Authentication Service
public final static String URL_LOGIN = baseUrl + "Login/log";

URLs.URL_LOGIN API URL


URL Android UI
UI

public class WebServiceAsyncHttpPost extends AsyncTask<Void, Void, Void>

public WebServiceAsyncHttpPost(Context context, String url, int id,


OnWebServiceProcess listener, Map<String, String>
params)

public interface OnWebServiceProcess {


void getServerValues(String response, int id, boolean isOk,
String exceptionType, int btnPosition);
void setServerError(int id, String msg);
}

4.3

4.1

25

4.1

View :
public class signature extends View
//
public signature(Context context, LinearLayout signatureContent)

View onTouchEvent
Base64
public String saveSignatureImage(View v) {
String base64ImageString = "";
Log.v("log_tag", "Width: " + v.getWidth());
Log.v("log_tag", "Height: " + v.getHeight());
if (mBitmap == null) {
mBitmap = Bitmap.createBitmap(signatureContainer.getWidth(),
signatureContainer.getHeight(), Bitmap.Config.RGB_565);
}
Canvas canvas = new Canvas(mBitmap);
try {
FileOutputStream mFileOutStream = new FileOutputStream(mypath);
v.draw(canvas);
mBitmap.compress(Bitmap.CompressFormat.PNG, 90, mFileOutStream);
mFileOutStream.flush();
mFileOutStream.close();
String url = Images.Media.insertImage(getActivity().getContentResolver(),
mBitmap, "title", null);
Log.v("log_tag", "url: " + url);
base64ImageString =
ImageUtils.getBase64String(ImageUtils.getByteArrayFromBitmap(mBitmap));

26

} catch (Exception e) {
e.printStackTrace();
}
return base64ImageString;
}

4.4

4.2

4.2



new DownloadTask(googleMap).execute(url);

Direction get
URL
private String getDirectionsUrl(LatLng origin, LatLng dest) {
String str_origin = "origin=" + origin.latitude + "," + origin.longitude;
String str_dest = "destination=" + dest.latitude + "," + dest.longitude;

27

String sensor = "sensor=false";


String mode = "mode=driving";
String key = "key=AIzaSyAqfgnUsN4SWkx3G54g_tk466kZMQBVmhw";
String parameters = str_origin + "&" + str_dest + "&" + sensor + "&"
+ mode + "&" + key;
String output = "json";
String url = "https://maps.googleapis.com/maps/api/directions/"
+ output + "?" + parameters;
return url;
}

DirectionsJSONParser
GoogleMap

4.5

GPS
public class DriverLocationListener implements LocationListener,
OnWebServiceProcess{}

LocationListener

@Override
public void onLocationChanged(Location location) {
Map<String, String> params = new HashMap<String, String>();
params.put(PostParametersKey.driver_id, driver_id);
params.put(ResponseKeyNames.latitude, "" + location.getLatitude());
params.put(ResponseKeyNames.longitude, "" + location.getLongitude());
params.put(ResponseKeyNames.heading, "" + location.getBearing());
sharedPrefCustom.saveString(PostParametersKey.lat, "" +
location.getLatitude());
sharedPrefCustom.saveString(PostParametersKey.lon, "" +
location.getLongitude());
sharedPrefCustom.saveString(PostParametersKey.head, "" +
location.getBearing());
Log.i("Location-->>", location.getLatitude() + ", " +
location.getLongitude() + ", " + location.getBearing());
new WebServiceAsyncHttpPost(context, URLs.URL_GPS_UPDATE,

28

RequestIds.GPS_UPDATE_RequestID , this, params, true,


0).execute();
}

LocationListener onLocationChanged

if (locMan.isProviderEnabled(LocationManager.GPS_PROVIDER)) {
Log.i("GPS", "OPENED");
if (ActivityCompat.checkSelfPermission(this,
Manifest.permission.ACCESS_FINE_LOCATION) !=
PackageManager.PERMISSION_GRANTED &&
ActivityCompat.checkSelfPermission(this,
Manifest.permission.ACCESS_COARSE_LOCATION) !=
PackageManager.PERMISSION_GRANTED) {
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M) {
requestPermissions(new
String[]{Manifest.permission.ACCESS_FINE_LOCATION,
Manifest.permission.ACCESS_COARSE_LOCATION}, 1001);
}
}else {
locMan.requestLocationUpdates(LocationManager.NETWORK_PROVIDER, 0, 0,
locationListenerGPS);
locMan.requestLocationUpdates(LocationManager.GPS_PROVIDER, 100, 1,
locationListenerNet);
}
}

Android LocationManager
6.0

29

TATA


2017


10
10

15 Tea Time
11 11
100

OPPO CEO

30

35

Android
GPS

31

Kavita


Indian Mesh Pvt.


Github
Android StackOverflow Android

32

[1] http://www.businessinsider.com/uber-rush-fedex-killer-released-2015-
10
[2] http://www.bbtnews.com.cn/2017/0322/186052.shtml
[3] Haslam, Karen. Macworld Expo: Optimised OS X sits on ' versatile' flash.
Macworld. January 12, 2007 [2007-10-15].
[4] Android 88%|
[5] http://api.ineal.me/tss/status
[6] Thompson, Bill, Time for Apple to face the music?, BBC News, 2007-09-
19
[7] Original iPhone OS 3 Developer Program License Agreement
[8] Google iOS Chrome Chromium -ithome
[9] https://www.apple.com/tw/environment/answers/
[10] https://support.microsoft.com/en-
us/lifecycle/search?sort=PN&alpha=Windows%20phone&Filter=FilterNO
[11] Bright, Peter. Windows Phone8 Windows 10
. Ars Technica. January 24, 2015.
[12] Yes, Windows 10 is Coming to Low-End Windows Phones. thurrot.com.
Petri. 2015 2 9 [February 11, 2015].
[13] Devine, Richard. Windows10 . Windows
Central. Mobile Nations. February 12, 2015 [February 12, 2015].
[14] Windows 10 Lumia . WMPoweruser.
Mobile First Network. 2015 3 30 .
[15] Windows 10 . The Verge. Vox Media. [July
2, 2015].
[16] https://hk.news.yahoo.com/%E8%81%96%E8%AA%95%E5%89%8D%E5%B0%B1%E6%9C
%89%E5%BE%97%E7%94%A8-windows-10-mobile-12-080007402.html
[17] Android 48%.Canalys 2011/02/01
[18] Android 1 10 . Android 2014/06/25
[19] https://technews.tw/2017/04/04/android-beats-windows-dominates-
global-internet-traffic/
[20] First SMS Trojan detected for smartphones running Android. Kaspersky
Lab. [2010-10-18].
[21] http://articles.businessinsider.com/2010-08-
02/tech/30055327_1_android-piracy-google

33

You might also like