Kotlin as a newly-born language, incorporates many language features. Here's how to install the Kotlin plugin in eclipse to write the Kotlin program
open Eclipse(eclipse requires Neon 4.6. Version or higher). The author uses version 4.6.1.
Choose Help--- Eclipse Marketplace ...
650) this.width=650; "src=" Https://s5.51cto.com/wyfs02/M01/98/BC/wKioL1k_02vQ4f9NAAA84SzuB1Y806.png "title=" Picture 2.png "alt=" Wkiol1k_02vq4f9naaa84szub1y806.png "/>
Then enter Kotlin Click Go. will appear Kotlin plug-in, click Install installation can, here because the author has been installed so display installed, if not installed is the install Word
650) this.width=650; "src=" Https://s1.51cto.com/wyfs02/M02/98/BC/wKiom1k_1DHS8e9gAADqrT-HMnE285.png "title=" Picture 3.png "alt=" Wkiom1k_1dhs8e9gaadqrt-hmne285.png "/>
Install plug-ins need network here, please keep the computer able to surf the Internet. The speed of installation depends on the Internet connection. After the installation is complete, restart Eclipse, restart Eclipse, select Windows--- perspective, Open perspective Then select Kotlin Click OK
650) this.width=650; "src=" Https://s3.51cto.com/wyfs02/M01/98/BC/wKiom1k_1WyC76LOAABUSBzRb8s774.png "style=" float : none; "title=" Image 4.png "alt=" Wkiom1k_1wyc76loaabusbzrb8s774.png "/>
650) this.width=650; "src=" Https://s5.51cto.com/wyfs02/M01/98/BC/wKioL1k_1W2hC1aSAAB46bqIaf8927.png "style=" float : none; "title=" Image 5.png "alt=" Wkiol1k_1w2hc1asaab46bqiaf8927.png "/>
will open the Kotlin development view, right click on the left mouse button to select New, if the following options indicate that the plug-in installation is complete
650) this.width=650; "src=" Https://s4.51cto.com/wyfs02/M00/98/BC/wKiom1k_1nyB6G0MAABbouj3KQw733.png "title=" Picture 6.png "alt=" Wkiom1k_1nyb6g0maabbouj3kqw733.png "/>
The Kotlin view can be used to write a Kotlin program that takes the main method as a portal. Write the Kotlin program below
Right-click the mouse to select New-KotlinProject, enter the project name Kotlin, then click Finish
650) this.width=650; "src=" Https://s2.51cto.com/wyfs02/M02/98/BC/wKioL1k_2G3iwZ-0AABoxnyAs2U133.png "title=" 1.png "alt=" Wkiol1k_2g3iwz-0aaboxnyas2u133.png "/>
650) this.width=650; "src=" Https://s3.51cto.com/wyfs02/M00/98/BC/wKioL1k_2Lbjo6esAACCWm1iA28199.png "title=" 2.png "alt=" Wkiol1k_2lbjo6esaaccwm1ia28199.png "/>
650) this.width=650; "src=" Https://s2.51cto.com/wyfs02/M00/98/BD/wKiom1k_2T-iK-EcAAAWi6aFPAY672.png "title=" 3.png "alt=" Wkiom1k_2t-ik-ecaaawi6afpay672.png "/>
Select SRC, right-click to select New-Kotlin File, Pop-up dialog box, enter HelloWorld in the Name column, then click Finish
650) this.width=650; "src=" Https://s5.51cto.com/wyfs02/M02/98/BD/wKiom1k_2fuTo-z2AABVA3YqjsU526.png "style=" float : none; "title=" 4.png "alt=" Wkiom1k_2futo-z2aabva3yqjsu526.png "/>
650) this.width=650; "src=" Https://s1.51cto.com/wyfs02/M00/98/BC/wKioL1k_2f2SG3xeAACEoEuxSQo666.png "style=" float : none; "title=" 5.png "alt=" Wkiol1k_2f2sg3xeaaceoeuxsqo666.png "/>
Then enter the following code in the Helloworld.kt file
Fun Main (args:array<string>) {println ("Hello, Kotlin")}
Right-click to select Runas-Kotlin application, then you can see the Hello,kotlin in the console
650) this.width=650; "src=" Https://s2.51cto.com/wyfs02/M00/98/BD/wKioL1k_22_jcTY8AAAXMoxMRm4402.png "title=" 6.png "alt=" Wkiol1k_22_jcty8aaaxmoxmrm4402.png "/>
A Kotlin starter program has finished running
This article is from the "Love_programme-love_life" blog, make sure to keep this source http://codemcx.blog.51cto.com/9638142/1935135
Eclipse Install Kotlin Plugin