Get Even More Visitors To Your Blog, Upgrade To A Business Listing >>

Blog Directory  >  Software Blogs  >  java tutorial : Blog to learn java programming software Blog  > 

2020-09-21 10:40
  Syntax class ChildClass(properties) extends SubClass(properties){   }   Exampleclass Employee(id: Int, name: String){override def toString() = s"id = $id… Read More
Scala: Traits
2020-09-21 10:39
  Scala do not have interface, but it support same functionality using traits. A trait in Scala can have abstract fields, class that implements this trait must provide… Read More
Scala: Packages
2020-09-21 10:35
Scala packages are similar to Java packages with few differences.   In Scala, a.   a single source file have contributions to multiple packages. b. &nb… Read More
2020-09-17 17:52
 Companion object has exactly same name as the class name and defined in the same source file. In Scala, both companion object and companion class can access each other private features… Read More
2020-09-17 17:42
If a method ‘op’ takes one argument then ‘a op b’ is same as a.op(b).   For example, 1.until(5) is same as ‘1 until 5’.scala> 1 until 5val res237:… Read More
2020-09-17 17:39
Using ‘this()’ you can define a constructor. Define default constructorclass Employee(id: Int, firstName: String, lastName: String) {def this() = {this(0, "no… Read More
2020-09-10 16:04
Tuple is a collection of different type values. Syntaxvar/val tupleName = (val1, val2…valN) Exampleval person1 = (1, "Krishna", 5.8, "male")Above statement define a tuple th… Read More

Share the post

java tutorial : Blog to learn java programming


Subscribe to Java Tutorial : Blog To Learn Java Programming

Get updates delivered right to your inbox!

Thank you for your subscription