Разделы презентаций


Android Development Without Java

Android Development With Scala

Слайды и текст этой презентации

Слайд 1Android Development Without Java

Android Development Without Java

Слайд 2Android Development With Scala

Android Development With Scala

Слайд 3 Scala

Scala

Слайд 4Scala is

Scala is

Слайд 5Scala is A Functional

Scala is  A Functional

Слайд 6Scala is A Functional Object Oriented

Scala is  A Functional Object Oriented

Слайд 7Scala is A Functional Object Oriented Statically Typed

Scala is  A Functional Object Oriented Statically Typed

Слайд 8Scala is A Functional Object Oriented Statically Typed Scalable

Scala is  A Functional Object Oriented Statically Typed Scalable

Слайд 9Scala is A Functional Object Oriented Statically Typed Scalable Language

Scala is  A Functional Object Oriented Statically Typed Scalable Language

Слайд 10Scala is A Functional Object Oriented Statically Typed Scalable Language Running on JVM

Scala is  A Functional Object Oriented Statically Typed Scalable Language  Running on JVM

Слайд 11Scala is A Functional Object Oriented Statically Typed Scalable Language Running on JVM and DalvikVM

Scala is  A Functional Object Oriented Statically Typed Scalable Language  Running on JVM and DalvikVM

Слайд 12 Why Scala

Why Scala

Слайд 13Java
public class MyActivity extends Activity {
ListView comments;

Button newComment;

@Override
void onCreate(Bundle bundle) { super.onCreate(bundle);

comments = (ListView) findViewById(R.id.comments);
newComment = (Button) findViewById(R.id.new_comment);
//...
}

public void sayHello() {
Toast.makeText(this, “Hello”, Toast.LENGTH_LONG).show();
}
}

Initialize context and views

Javapublic class MyActivity extends Activity {  ListView comments;  Button newComment; @Override  void onCreate(Bundle bundle)

Слайд 14Java with RoboGuice
public class MyActivity extends RoboActivity {
@Inject

Application context;
@Inject SessionManager sessionManager;

@Inject(R.id.comments) ListView comments;

@Inject(R.id.new_comment) Button newComment;





public void sayHello() {
Toast.makeText(this, “Hello”, Toast.LENGTH_LONG).show();
}
}

Inject views

Java with RoboGuicepublic class MyActivity extends RoboActivity {  @Inject Application context;  @Inject SessionManager sessionManager; @Inject(R.id.comments)

Слайд 15GO HOME ANDROID. YOU ARE DRUNK.

GO HOME ANDROID. YOU ARE DRUNK.

Слайд 16Scala
class MyActivity extends ScalaActivity {


lazy val SessionManager

lazy val comments = findView(TR.comments)
lazy val newComment = findView(TR.new_comment)





def sayHello() = “Hello”.toast()

}

Lazily load views

Toast using implicit conversion

Implicit Context

Scalaclass MyActivity extends ScalaActivity {   lazy val SessionManager lazy val comments = findView(TR.comments) lazy val

Слайд 17 A Sample Project

A Sample Project

Слайд 18 shadowsocks

shadowsocks

Слайд 19shadowsocks
github/shadowsocks/shadowsocks-android
written in C/C++ and Scala

modules
shadowsocks-libev: secured socks5 proxy in pure

C
shadowsocks-android: UI/Android interface in Scala
lwIP/tun2socks: user space TCP/IP stack in

C++
pdnsd/iptables/redsocks: native porting for android
shadowsocksgithub/shadowsocks/shadowsocks-androidwritten in C/C++ and Scalamodulesshadowsocks-libev: secured socks5 proxy in pure Cshadowsocks-android: UI/Android interface in ScalalwIP/tun2socks: user space

Слайд 20Project Structure
project/
Build.scala
plugins.sbt
src/
main/
res/
assets/
jni/
libs/

native libraries>
scala/
java/
AndroidManifest.xml
test/

Project Structureproject/	Build.scala			 	plugins.sbt			src/	main/		res/					assets/					jni/					libs/					scala/					java/					AndroidManifest.xml	 		test/

Слайд 21SBT
Simple Build Tool for Scala / Java
Ant, Maven, Gradle like

tool in Scala

github/jberkel/android-plugin
SBT plugin for Android
Dependency management, unit test, instrumentation,

auto tasks, etc
SBTSimple Build Tool for Scala / JavaAnt, Maven, Gradle like tool in Scalagithub/jberkel/android-pluginSBT plugin for AndroidDependency management,

Слайд 22Components
UI
ActionBarSherlock
SwitchBackport
Crouton
UnifiedPreference
UniversalImageLoader

Libraries
DNSJava
Analytics
AdMob


ComponentsUIActionBarSherlockSwitchBackportCroutonUnifiedPreferenceUniversalImageLoaderLibrariesDNSJavaAnalyticsAdMob

Слайд 23Components

Components

Слайд 24Best Practices
Proguard
Aggressive default rules

IntelliJ IDEA
Best IDE for Scala and Android

Continuous

Integration
Travis is best, Jenkins works well

Best PracticesProguardAggressive default rulesIntelliJ IDEABest IDE for Scala and AndroidContinuous IntegrationTravis is best, Jenkins works well

Слайд 25 Questions?

Questions?

Слайд 26 Thanks!

Thanks!

Слайд 27About Me
Max Lv
Member of Tangcha Project
字节社 for Android, http://zijieshe.com

Major Contributor

of GoAgent Project
github/madeye/gaeproxy

Core maintainer of Shadowsocks Project
github/madeye/shadowsocks-libev
github/shadowsocks/shadowsocks-android

About MeMax LvMember of Tangcha Project字节社 for Android, http://zijieshe.comMajor Contributor of GoAgent Projectgithub/madeye/gaeproxyCore maintainer of Shadowsocks Projectgithub/madeye/shadowsocks-libev

Обратная связь

Если не удалось найти и скачать доклад-презентацию, Вы можете заказать его на нашем сайте. Мы постараемся найти нужный Вам материал и отправим по электронной почте. Не стесняйтесь обращаться к нам, если у вас возникли вопросы или пожелания:

Email: Нажмите что бы посмотреть 

Что такое TheSlide.ru?

Это сайт презентации, докладов, проектов в PowerPoint. Здесь удобно  хранить и делиться своими презентациями с другими пользователями.


Для правообладателей

Яндекс.Метрика