Kotlin is a multiplatform programming language that can be used to build applications for Android, iOS, Web, Desktop and Backend. The document describes a sample app built with Kotlin that shares code across multiple platforms using common code, models and presenters. It includes code snippets for the common module, Android, Web, iOS and Backend implementations, demonstrating how to share functionality across platforms with Kotlin.
The web is growing fast and online games and other compute-intensive applications expand their user-bases every day. These trends create a growing demand on performance in JavaScript applications. Even though JavaScript has benefited from huge performance improvements in recent years, there is great potential for an even faster web. Browser technologies such as asm.js or Google’s NativeClient enable near-native performance in browsers. More recent efforts led to the specification of WebAssembly, the future vendor-independent standard for native webapps. This talk takes a closer look at Emscripten, a toolchain that transpiles C++ to asm.js. The talk answers questions regarding performance and about the integration with the popular CMake build system.
Apache Tuscany is an open source project that simplifies the development, deployment and management of distributed applications built as compositions of service components. It is based on the Service Component Architecture specifications being defined by the OASIS Open SCA Collaboration. This presentation describe the experience to OSGi enable the Tuscany SCA runtime.
Maven, Eclipse and OSGi Working Together - Carlos Sanchezmfrancis
OSGi DevCon 2008
With the growing popularity of Apache Maven, Eclipse, and OSGi, the most frequently-asked questions are: "Can they work together?" and, "Do they fight for the same space?" This tutorial will cover the strengths and weaknesses of each, explains where they overlap, and how they complement each other so you can get maximum productivity. It pays special attention to the build process, dependency management, collaboration, repository management, and available tools, as well as the future direction of the technologies. The solutions proposed will be based on the work done in the Apache Maven and Apache Felix projects, along with several Eclipse Foundation projects like Eclipse PDE and Eclipse Buckminster.
The web is growing fast and online games and other compute-intensive applications expand their user-bases every day. These trends create a growing demand on performance in JavaScript applications. Even though JavaScript has benefited from huge performance improvements in recent years, there is great potential for an even faster web. Browser technologies such as asm.js or Google’s NativeClient enable near-native performance in browsers. More recent efforts led to the specification of WebAssembly, the future vendor-independent standard for native webapps. This talk takes a closer look at Emscripten, a toolchain that transpiles C++ to asm.js. The talk answers questions regarding performance and about the integration with the popular CMake build system.
Apache Tuscany is an open source project that simplifies the development, deployment and management of distributed applications built as compositions of service components. It is based on the Service Component Architecture specifications being defined by the OASIS Open SCA Collaboration. This presentation describe the experience to OSGi enable the Tuscany SCA runtime.
Maven, Eclipse and OSGi Working Together - Carlos Sanchezmfrancis
OSGi DevCon 2008
With the growing popularity of Apache Maven, Eclipse, and OSGi, the most frequently-asked questions are: "Can they work together?" and, "Do they fight for the same space?" This tutorial will cover the strengths and weaknesses of each, explains where they overlap, and how they complement each other so you can get maximum productivity. It pays special attention to the build process, dependency management, collaboration, repository management, and available tools, as well as the future direction of the technologies. The solutions proposed will be based on the work done in the Apache Maven and Apache Felix projects, along with several Eclipse Foundation projects like Eclipse PDE and Eclipse Buckminster.
Building Modern Apps using Android Architecture ComponentsHassan Abid
Android architecture components are part of Android Jetpack. They are a collection of libraries that help you design robust, testable, and maintainable apps. In this talk, We will cover LiveData, ViewModel, Room and lifecycle components. We will go through practical code example to understand modern android app architecture especially MVVM architecture.
Le temps est révolu où Java EE ne serait qu’à développer des applications de mise à jour de données, avec JSF / EJB / JPA. Aujourd’hui Java EE s’est assoupli et s’est ouvert sur le monde, avec CDI comme clé de voûte et a repoussé nos limites grâce à des capacités d’extension puissantes et faciles d’utilisation comme JCA.
Dans un premier temps, nous reviendrons rapidement sur la place de CDI dans JavaEE 7 et sur ses mécanismes d’extension. Dans un deuxième temps, nous verrons les techniques de connecteurs JCA et comment ils peuvent aussi constituer une possibilité d’ouverture simple à mettre en œuvre. JCA fournit des techniques pour gérer des connexions sortantes ou entrantes, sur des formats ou protocoles variés.
Esta charla comprende las lecciones aprendidas convirtiendo la app de Android de Teambox (una app repleta de deuda técnica y con un alto nivel de acoplamiento entre clases), en la versión actual de Redbooth, que intenta cumplir la arquitectura Hexagonal y los principios SOLID. Durante la exposición explicaremos como fuimos desenredando el código paso a paso; como aplicamos por partes los conceptos de la arquitectura hexagonal; como dejamos de lado componentes del framework de Android que dificultaban el mantenimiento de la app; y que errores cometimos, como los solucionamos y como se podrían haber evitado.
Battle Of The Microservice Frameworks: Micronaut versus Quarkus edition! Michel Schudel
Micronaut and Quarkus are two cool emerging Java backend frameworks that aim to solve some problems that exist in current frameworks, like faster startup, low memory footprint, and support for ahead-of-time compilation using GraalVM. In this session, we'll square off both frameworks against each other.
How do they compare, what are the stronger and weaker points of both frameworks?
We'll compare the following features:
Initializing your project
Building your first restcontroller / programming model
Startup time
Database support
Integration test support
Building native images
Memory usage and JAR sizes
Ease of cloud deployment
In the end, we might have a clear winner! ... or will we?
«Продакшн в Kotlin DSL» Сергей РыбалкинMail.ru Group
- Как пришли к использованию и разработки своих DSL
- Посмотрим примеры используемых в экосистеме DSL - gradle, spek, spring
- Рассмотрим базис для конструирования DSL на примере kohttp
Red Hat JBoss BRMS and BPMS Workbench and Rich Client TechnologyMark Proctor
This is an overview video that shows the scope of work and technology used within the Red Hat JBoss BRMS and BPMS platforms.
The technology presented builds with GWT, Errai and UberFire as the foundation. Over 2015 we'll be working to make it for end users to consume the bits they need, paying for only what they use, so others can make power web platforms like BRMS and BPMS.
Water scarcity is the lack of fresh water resources to meet the standard water demand. There are two type of water scarcity. One is physical. The other is economic water scarcity.
NO1 Uk best vashikaran specialist in delhi vashikaran baba near me online vas...Amil Baba Dawood bangali
Contact with Dawood Bhai Just call on +92322-6382012 and we'll help you. We'll solve all your problems within 12 to 24 hours and with 101% guarantee and with astrology systematic. If you want to take any personal or professional advice then also you can call us on +92322-6382012 , ONLINE LOVE PROBLEM & Other all types of Daily Life Problem's.Then CALL or WHATSAPP us on +92322-6382012 and Get all these problems solutions here by Amil Baba DAWOOD BANGALI
#vashikaranspecialist #astrologer #palmistry #amliyaat #taweez #manpasandshadi #horoscope #spiritual #lovelife #lovespell #marriagespell#aamilbabainpakistan #amilbabainkarachi #powerfullblackmagicspell #kalajadumantarspecialist #realamilbaba #AmilbabainPakistan #astrologerincanada #astrologerindubai #lovespellsmaster #kalajaduspecialist #lovespellsthatwork #aamilbabainlahore#blackmagicformarriage #aamilbaba #kalajadu #kalailam #taweez #wazifaexpert #jadumantar #vashikaranspecialist #astrologer #palmistry #amliyaat #taweez #manpasandshadi #horoscope #spiritual #lovelife #lovespell #marriagespell#aamilbabainpakistan #amilbabainkarachi #powerfullblackmagicspell #kalajadumantarspecialist #realamilbaba #AmilbabainPakistan #astrologerincanada #astrologerindubai #lovespellsmaster #kalajaduspecialist #lovespellsthatwork #aamilbabainlahore #blackmagicforlove #blackmagicformarriage #aamilbaba #kalajadu #kalailam #taweez #wazifaexpert #jadumantar #vashikaranspecialist #astrologer #palmistry #amliyaat #taweez #manpasandshadi #horoscope #spiritual #lovelife #lovespell #marriagespell#aamilbabainpakistan #amilbabainkarachi #powerfullblackmagicspell #kalajadumantarspecialist #realamilbaba #AmilbabainPakistan #astrologerincanada #astrologerindubai #lovespellsmaster #kalajaduspecialist #lovespellsthatwork #aamilbabainlahore #Amilbabainuk #amilbabainspain #amilbabaindubai #Amilbabainnorway #amilbabainkrachi #amilbabainlahore #amilbabaingujranwalan #amilbabainislamabad
More Related Content
Similar to Kotlin - A language to dominate them all
Building Modern Apps using Android Architecture ComponentsHassan Abid
Android architecture components are part of Android Jetpack. They are a collection of libraries that help you design robust, testable, and maintainable apps. In this talk, We will cover LiveData, ViewModel, Room and lifecycle components. We will go through practical code example to understand modern android app architecture especially MVVM architecture.
Le temps est révolu où Java EE ne serait qu’à développer des applications de mise à jour de données, avec JSF / EJB / JPA. Aujourd’hui Java EE s’est assoupli et s’est ouvert sur le monde, avec CDI comme clé de voûte et a repoussé nos limites grâce à des capacités d’extension puissantes et faciles d’utilisation comme JCA.
Dans un premier temps, nous reviendrons rapidement sur la place de CDI dans JavaEE 7 et sur ses mécanismes d’extension. Dans un deuxième temps, nous verrons les techniques de connecteurs JCA et comment ils peuvent aussi constituer une possibilité d’ouverture simple à mettre en œuvre. JCA fournit des techniques pour gérer des connexions sortantes ou entrantes, sur des formats ou protocoles variés.
Esta charla comprende las lecciones aprendidas convirtiendo la app de Android de Teambox (una app repleta de deuda técnica y con un alto nivel de acoplamiento entre clases), en la versión actual de Redbooth, que intenta cumplir la arquitectura Hexagonal y los principios SOLID. Durante la exposición explicaremos como fuimos desenredando el código paso a paso; como aplicamos por partes los conceptos de la arquitectura hexagonal; como dejamos de lado componentes del framework de Android que dificultaban el mantenimiento de la app; y que errores cometimos, como los solucionamos y como se podrían haber evitado.
Battle Of The Microservice Frameworks: Micronaut versus Quarkus edition! Michel Schudel
Micronaut and Quarkus are two cool emerging Java backend frameworks that aim to solve some problems that exist in current frameworks, like faster startup, low memory footprint, and support for ahead-of-time compilation using GraalVM. In this session, we'll square off both frameworks against each other.
How do they compare, what are the stronger and weaker points of both frameworks?
We'll compare the following features:
Initializing your project
Building your first restcontroller / programming model
Startup time
Database support
Integration test support
Building native images
Memory usage and JAR sizes
Ease of cloud deployment
In the end, we might have a clear winner! ... or will we?
«Продакшн в Kotlin DSL» Сергей РыбалкинMail.ru Group
- Как пришли к использованию и разработки своих DSL
- Посмотрим примеры используемых в экосистеме DSL - gradle, spek, spring
- Рассмотрим базис для конструирования DSL на примере kohttp
Red Hat JBoss BRMS and BPMS Workbench and Rich Client TechnologyMark Proctor
This is an overview video that shows the scope of work and technology used within the Red Hat JBoss BRMS and BPMS platforms.
The technology presented builds with GWT, Errai and UberFire as the foundation. Over 2015 we'll be working to make it for end users to consume the bits they need, paying for only what they use, so others can make power web platforms like BRMS and BPMS.
Water scarcity is the lack of fresh water resources to meet the standard water demand. There are two type of water scarcity. One is physical. The other is economic water scarcity.
NO1 Uk best vashikaran specialist in delhi vashikaran baba near me online vas...Amil Baba Dawood bangali
Contact with Dawood Bhai Just call on +92322-6382012 and we'll help you. We'll solve all your problems within 12 to 24 hours and with 101% guarantee and with astrology systematic. If you want to take any personal or professional advice then also you can call us on +92322-6382012 , ONLINE LOVE PROBLEM & Other all types of Daily Life Problem's.Then CALL or WHATSAPP us on +92322-6382012 and Get all these problems solutions here by Amil Baba DAWOOD BANGALI
#vashikaranspecialist #astrologer #palmistry #amliyaat #taweez #manpasandshadi #horoscope #spiritual #lovelife #lovespell #marriagespell#aamilbabainpakistan #amilbabainkarachi #powerfullblackmagicspell #kalajadumantarspecialist #realamilbaba #AmilbabainPakistan #astrologerincanada #astrologerindubai #lovespellsmaster #kalajaduspecialist #lovespellsthatwork #aamilbabainlahore#blackmagicformarriage #aamilbaba #kalajadu #kalailam #taweez #wazifaexpert #jadumantar #vashikaranspecialist #astrologer #palmistry #amliyaat #taweez #manpasandshadi #horoscope #spiritual #lovelife #lovespell #marriagespell#aamilbabainpakistan #amilbabainkarachi #powerfullblackmagicspell #kalajadumantarspecialist #realamilbaba #AmilbabainPakistan #astrologerincanada #astrologerindubai #lovespellsmaster #kalajaduspecialist #lovespellsthatwork #aamilbabainlahore #blackmagicforlove #blackmagicformarriage #aamilbaba #kalajadu #kalailam #taweez #wazifaexpert #jadumantar #vashikaranspecialist #astrologer #palmistry #amliyaat #taweez #manpasandshadi #horoscope #spiritual #lovelife #lovespell #marriagespell#aamilbabainpakistan #amilbabainkarachi #powerfullblackmagicspell #kalajadumantarspecialist #realamilbaba #AmilbabainPakistan #astrologerincanada #astrologerindubai #lovespellsmaster #kalajaduspecialist #lovespellsthatwork #aamilbabainlahore #Amilbabainuk #amilbabainspain #amilbabaindubai #Amilbabainnorway #amilbabainkrachi #amilbabainlahore #amilbabaingujranwalan #amilbabainislamabad
CFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptxR&R Consult
CFD analysis is incredibly effective at solving mysteries and improving the performance of complex systems!
Here's a great example: At a large natural gas-fired power plant, where they use waste heat to generate steam and energy, they were puzzled that their boiler wasn't producing as much steam as expected.
R&R and Tetra Engineering Group Inc. were asked to solve the issue with reduced steam production.
An inspection had shown that a significant amount of hot flue gas was bypassing the boiler tubes, where the heat was supposed to be transferred.
R&R Consult conducted a CFD analysis, which revealed that 6.3% of the flue gas was bypassing the boiler tubes without transferring heat. The analysis also showed that the flue gas was instead being directed along the sides of the boiler and between the modules that were supposed to capture the heat. This was the cause of the reduced performance.
Based on our results, Tetra Engineering installed covering plates to reduce the bypass flow. This improved the boiler's performance and increased electricity production.
It is always satisfying when we can help solve complex challenges like this. Do your systems also need a check-up or optimization? Give us a call!
Work done in cooperation with James Malloy and David Moelling from Tetra Engineering.
More examples of our work https://www.r-r-consult.dk/en/cases-en/
Saudi Arabia stands as a titan in the global energy landscape, renowned for its abundant oil and gas resources. It's the largest exporter of petroleum and holds some of the world's most significant reserves. Let's delve into the top 10 oil and gas projects shaping Saudi Arabia's energy future in 2024.
Hierarchical Digital Twin of a Naval Power SystemKerry Sado
A hierarchical digital twin of a Naval DC power system has been developed and experimentally verified. Similar to other state-of-the-art digital twins, this technology creates a digital replica of the physical system executed in real-time or faster, which can modify hardware controls. However, its advantage stems from distributing computational efforts by utilizing a hierarchical structure composed of lower-level digital twin blocks and a higher-level system digital twin. Each digital twin block is associated with a physical subsystem of the hardware and communicates with a singular system digital twin, which creates a system-level response. By extracting information from each level of the hierarchy, power system controls of the hardware were reconfigured autonomously. This hierarchical digital twin development offers several advantages over other digital twins, particularly in the field of naval power systems. The hierarchical structure allows for greater computational efficiency and scalability while the ability to autonomously reconfigure hardware controls offers increased flexibility and responsiveness. The hierarchical decomposition and models utilized were well aligned with the physical twin, as indicated by the maximum deviations between the developed digital twin hierarchy and the hardware.
Welcome to WIPAC Monthly the magazine brought to you by the LinkedIn Group Water Industry Process Automation & Control.
In this month's edition, along with this month's industry news to celebrate the 13 years since the group was created we have articles including
A case study of the used of Advanced Process Control at the Wastewater Treatment works at Lleida in Spain
A look back on an article on smart wastewater networks in order to see how the industry has measured up in the interim around the adoption of Digital Transformation in the Water Industry.
Industrial Training at Shahjalal Fertilizer Company Limited (SFCL)MdTanvirMahtab2
This presentation is about the working procedure of Shahjalal Fertilizer Company Limited (SFCL). A Govt. owned Company of Bangladesh Chemical Industries Corporation under Ministry of Industries.
5. Thanks
@Kotlin team, take a look to KotlinConf
app:
https://github.com/JetBrains/kotlinconf-app
@MarcinMoskala, He has 2 multiplatform
repos that are really helpful:
https://github.com/MarcinMoskala
@wiyarmir, he has also a multiplatform
project:
https://github.com/wiyarmir
@victorfriasv for the Votlin logo! Looks
really nice! :)
https://www.linkedin.com/in/victorfriasv
@JacoboCL, moral support!!
https://github.com/JacoboCL
7. Kotlin
- Born in 2012
- Created by JetBrains
- 100% interoperability with Java programming
Language
- Compiles to Bytecode, assembler, LLVM, JS…
- Official Android Language since May of 2017
- Kotlin version: v1.2.71
- Kotlin Native version: v0.9.3
8. Kotlin features
● Data classes
● Singletons
● Extension functions
● Lambdas
● Null safety
● Inmutable
● High order functions
● Smart casting
● Named parameters
● When
Multiplatform!!
data class Rate(val id: Int, val value: Int)
object EmptyResultException
fun ImageView.load(drawableId: Int) {
Glide.with(this)
.load(drawableId)
.into(this)
}
15. Client Architecture
Splash View Home View Detail View
Splash
Presenter
List Presenter
Detail
Presenter
Platform
Splash View
Platform
Home View
Pltaform
Detail View
Repositories
Use Cases
Local
DataSource
Remote
DataSource
Common
DataSource
Platform Local
DataSource
Repositories
Impl
Error Handler Executor
Platform
Error Handler
Platform
Executor
Models
16. Sharing Models
Client Backend
Domain
Models
@Serializable
data class Talk(val id: Int,
val name: String,
val description: String,
val speakers: List<Speaker>,
val track: Track,
val time: Time)
@Serializable
data class Speaker(
val twitter: String,
val linkedin: String,
val name: String,
val bio: String,
val photoUrl: String)
@Serializable
data class TalksResponse(val talks: List<Talk>)
@Serializable
data class Rate(val id: Int, val value: Int)
enum class Track {
BUSINESS, DEVELOPMENT, MAKER, ALL
}
17. Executor and Error Handler
interface Executor {
val main: CoroutineDispatcher
}
interface ErrorHandler {
fun convert(error: Error): String
}
18. Coroutines
private fun getTalks(track: Track) {
GlobalScope.launch(context = executor.main) {
val talks = when (track) {
Track.ALL -> getAllTalks(repository)
else -> getTalksByTrack(track, repository)
}
view.showTalks(talks)
view.hideProgress()
}
}
19. Presenter
abstract class Presenter<out V : Presenter.View>(protected val
errorHandler: ErrorHandler, val view: V) {
abstract fun initialize()
abstract fun destroy()
protected fun onError(callback: (String) -> Unit): (Error) -> Unit = {
view.hideProgress()
callback(errorHandler.convert(it))
}
interface View {
fun showProgress()
fun hideProgress()
fun showError(error: String)
fun showMessage(message: String)
}
}
20. Presenters
class DetailPresenter(private val repository: Repository, private val executor: Executor,
errorHandler: ErrorHandler, view: DetailView)
: Presenter<DetailView>(errorHandler, view) {
override fun initialize() {
view.showProgress()
GlobalScope.launch(executor.main) {
val talk = getTalkDetail(view.getTalkId(), repository)
view.showTalk(talk)
view.hideProgress()
}
}
fun onBackClicked() {
view.navigateToList()
}
fun onRateChange(rate: Int) {
GlobalScope.launch(executor.new) {
rateTalk(Rate(id = view.getTalkId(), value =
rate), repository)
}
view.showRate(rate)
21. Use Cases
suspend fun getAllTalks(repository: Repository): List<Talk> =
repository.getTalks()
suspend fun getTalkDetail(id: Int, repository: Repository): Talk =
repository.getTalk(talkId = id)
suspend fun getTalksByTrack(track: Track, repository: Repository):
List<Talk> = repository.getTalksByTrack(track = track)
suspend fun rateTalk(rate: Rate, repository: Repository): Unit =
repository.rateTalk(rate = rate)
fun saveTalk(talk: Talk, repository: Repository): Unit =
repository.saveTalk(talk = talk)
fun getTalkRate(talkId: Int, repository: Repository): Int =
repository.getRate(talkId = talkId)
22. Remote data source
class CommonRemoteDataSource : RemoteDataSource {
private val endPoint: String = "ENDPOINT"
private val client: HttpClient = HttpClient {}
override suspend fun getTalks(): List<Talk> =
JSON.parse<TalksResponse>(client.get { apiUrl("talk") }).talks
override suspend fun getTalk(talkId: Int): Talk = JSON.parse(client.get {
apiUrl("talk/$talkId") })
override suspend fun getTalksByTrack(track: String): List<Talk> =
JSON.parse<TalksResponse>(client.get { apiUrl("talk/$track") }).talks
override suspend fun rateTalk(rate: Rate): Unit = client.post {
apiUrl("talk/rate")
body = JSON.stringify(rate)
}
}