App Development

Tutorials for Android app development

LearnJava Basics for Android Development – Part 1  September 29, 2021 – 10:49 pm

Half-full mug on tableThere are a number of ways to create apps for Android devices, but the recommended method for most developers is to write native apps using Java and the Android SDK. Java for Android apps is both similar and quite different from other types of Java applications.

If you have experience with Java (or a similar language) then you’ll probably feel pretty comfortable diving right into the code and learning how to use the Android SDK to make your app run. But if you’re new to programming or object-oriented languages then you’ll probably want to get familiar with the syntax of the Java language and how to accomplish basic programming tasks before learning how to use the Android SDK.

Java the Programming Language

Programming languages, like regular languages, are different ways to communicate to a computer how you want it to act. Programming languages allow us to instruct a computer step-by-step how to manipulate data, collect input from users, and display things on a screen, among other things.

Way down on a microscopic level, the processor of a computer sends electrical signals back and forth that control how it operates. High level programming languages like Java mean that we can write these instructions in an abstract manner using words and symbols, and the computer will take care of translating these instructions that we can understand all the way down to electrical impulses that the processor can understand.

Not to get ahead of ourselves, but Java is a statically-typed, object-oriented language. Let’s break this down:

  • “Statically-typed” – Programming at its core is really about working with data. Pieces of data are stored as variables, which are basically containers that hold data. Statically-typed languages like Java require us to declare what type of data each variable (or container) will hold. So for example, if a variable is supposed to hold a number, we need to say so, and we won’t be allowed to put something else like a letter in it. Statically-typed also means that all the variables will be checked before the program even runs, and we’ll be presented with an error if we forget to declare a type of data or declare the wrong one.
  • “Object-oriented” – An object-oriented language is one that is built around the concept of objects. In the physical world, take a look around the room and think of each thing as an object. For example, on my desk right now I have a mug. As an object, it’s name is “mug” and it has properties about it like its color and how much liquid it will hold. Object-oriented languages allow us to define objects like mugs and access their properties in our code. We can also send messages to objects, so for my mug I might want to know “Is it empty?” We can then create and manipulate all sorts of objects to do different things in our app. For example, we can use the Camera object to take a photo. The Camera object represents the physical camera on an Android phone, but in a way that we can interact with in code.


Related posts:

  1. Software for mobile app development
  2. Location Based app development
  3. Softwares needed for Android app development
  4. storyboard for app development
  5. software for Android app development