Skip to content

Instantly share code, notes, and snippets.

View aminulaust's full-sized avatar

Md. Aminul Islam aminulaust

View GitHub Profile
MSkgQCAoUEFTUykKMikgQCAoUEFTUykKMykgMTAgKFBBU1MpCjQpIDIwIChQQVNTKQo1KSBteDEudGl0YW4uZW1haWwgKFBBU1MpCjYpIG14Mi50aXRhbi5lbWFpbCAoUEFTUykKNykgQCAoUEFTUykKOCkgdj1zcGYxIGluY2x1ZGU6c3BmLnRpdGFuLmVtYWlsIH5hbGwgKFBBU1Mp
@aminulaust
aminulaust / index.js
Created November 9, 2019 13:45
switch between different pages
function doClick(e) {
//alert($.label.text);
var nextScreen = Alloy.createController('nameOfNextScreen', {sushi: "california roll" }).getView();
nextScreen.open();
}
$.index.open();
Automatic summarization is the process of shortening a text document with software, in order to create a summary with the major points of the original document. Technologies that can make a coherent summary take into account variables such as length, writing style and syntax.
Automatic data summarization is part of machine learning and data mining. The main idea of summarization is to find a subset of data which contains the "information" of the entire set. Such techniques are widely used in industry today. Search engines are an example; others include summarization of documents, image collections and videos. Document summarization tries to create a representative summary or abstract of the entire document, by finding the most informative sentences, while in image summarization the system finds the most representative and important (i.e. salient) images.[citation needed] For surveillance videos, one might want to extract the important events from the uneventful contex.
@aminulaust
aminulaust / packagePermissions.js
Last active September 19, 2019 12:29
android.permission.REQUEST_INSTALL_PACKAGES
var win = Ti.UI.createWindow({
});
win.addEventListener("open", function(e) {
const packagePermissions = ['android.permission.REQUEST_INSTALL_PACKAGES','android.permission.WRITE_EXTERNAL_STORAGE',
'android.permission.READ_EXTERNAL_STORAGE'];
Ti.Android.requestPermissions(packagePermissions, function(e) {
if (e.success) {
Ti.API.info('SUCCESS');
} else {
Ti.API.info('ERROR: ' + e.error);
@aminulaust
aminulaust / NETWORK_NONE.js
Last active March 26, 2019 15:36
Titanium.Network.NETWORK_NONE
var win = Ti.UI.createWindow({
title : "Online",
backgroundColor : '#fff'
});
var getDetailsBtn = Ti.UI.createButton({
width : 100, //width of the button
height : 50, // Height of the button
title : 'Get Details' //Text that nned to display on button
});
@aminulaust
aminulaust / online.js
Last active March 26, 2019 15:16
Ti.Network.online
var win = Ti.UI.createWindow({
title : "Online",
backgroundColor : '#fff'
});
var getDetailsBtn = Ti.UI.createButton({
width : 100, //width of the button
height : 50, // Height of the button
title : 'Get Details' //Text that nned to display on button
});
@aminulaust
aminulaust / location.js
Last active March 21, 2019 14:30
location
function doClick(e) {
var hasLocationPermission = Ti.Geolocation
.hasLocationPermissions(Ti.Geolocation.AUTHORIZATION_WHEN_IN_USE);
if (!hasLocationPermission) {
Ti.Geolocation.requestLocationPermissions(
Ti.Geolocation.AUTHORIZATION_WHEN_IN_USE, function(e) {
if (e.success) {
getLocation();
// permission granted
@aminulaust
aminulaust / Service.js
Last active January 14, 2019 12:54
Foreground Service
Ti.API.info("@@@ Service started.");
// Gets an intent used to resume the app if running in the background.
function getAppResumeIntent() {
var intent = Ti.App.Android.launchIntent;
if (!intent) {
intent = Ti.Android.createIntent({});
}
return intent;
}
var win = Ti.UI.createWindow({
title : "Control Window",
backgroundColor : "white",
layout : "vertical"
});
var bt = Ti.UI.createButton({
title : "SD Card Test",
top : 10,
height : Ti.UI.SIZE,
var win = Ti.UI.createWindow({
});
var lbl = Ti.UI.createLabel({
text : "click to add a contact"
});
win.add(lbl);
lbl.addEventListener(