This documentation is not maintained. Please refer to doc.castsoftware.com/technologies to find the latest updates.

Summary: This document provides information about the extension providing Android technologies support for the JEE Analyzer.

What's new?

Please see Android 1.1 - Release Notes for more information.

Description

This extension provides support for Android technologies. This extension works together with the JEE Analyzer.

In what situation should you install this extension?

If your JEE application source code uses Android technologies you should install this extension.

Features

AndroidManifest file

This file will be analyzed to understand whether the application is indeed an Android application. Links between the Android application and the Activity class are resolved.

UI Controls support

A UI XML file will be created as the common entry point for all widgets. Below is a list of controls supported by this extension:

  • Layout(ListView, LinearLayout, RelativeLayout, WebView, GridView)
  • TextView, AutoCompleteTextView
  • Button, ImageButton, RadioButton
  • EditText, CheckBox, Spinner, TimePicker
  • menu, item, group

Other widgets will be resolved to find the widget type. If it cannot be found, the widget will be created as a CAST_Android_UndefinedWidget type - for example widgets implemented by the client.

Android Event handling support from XML file

  • onClickListener()
  • onLongClickListener()
  • onFocusChangeListener()
  • onKeyListener()
  • onTouchListener()
  • onCreateContextMenu()

Android Event handling support from setEventListenner and addEventListener in widgets

  • The lambda function can be used to define the event handler. Sample: Button.setOnClickListenner(new View.OncLickListentHandler{...}), with lamda function: Button.setOnClickListenner( (v) → {})

Android Type XML support

  • Widget Layout (RelativeLayout, LinearLayout, menu)
  • AndroidManifest file

WebServices support

Support for third-party WebServices is provided:

  • httpClient library with namespace cz.msebera.android.httpclient.
  • httpClient library with namespace org.apache.http.client.HttpClient.
  • httpUrlConnection from java.net.URL and java.net.HttpURLConnection.
  • Create webservice via AsyncTask class of Android.
  • Transaction between client and server on fullstack project.
  • Transaction between event handler widget and http method call.

End to End transactions

  • End to End transactions are resolved:
    • Entry point: layout ui xml file
    • End point: web service, persisting data

Supported Android versions

VersionSupported
4.4 - 8.0

(tick)

Supported Technologies 

TechnologySupported
Java

(tick)

Kotlin(error)

Function Point, Quality and Sizing support

This extension provides the following support:

  • Function Points (transactions): a green tick indicates that OMG Function Point counting and Transaction Risk Index are supported
  • Quality and Sizing: a green tick indicates that CAST can measure size and that a minimum set of Quality Rules exist
Function Points
(transactions)
(tick)
Quality and Sizing(tick)

CAST AIP compatibility

This extension is compatible with:

CAST AIP release
Supported
8.3.x(tick)
8.2.x(tick)

Supported DBMS servers

This extension is compatible with the following DBMS servers:

DBMSSupported
CSS(tick)
Oracle(tick)
Microsoft SQL Server(error)

Prerequisites

(tick)An installation of any compatible release of CAST AIP (see table above)

Dependencies with other extensions

Some CAST extensions require the presence of other CAST extensions in order to function correctly. The Android extension requires that the following other CAST extensions are also installed:

  • JEE Analyzer
  • com.castsoftware.internal.platform (internal extension) ≥ 0.8.0
  • Web services linker service (internal technical extension) ≥ 1.6.1 funcrel

Note that:

  • when using the CAST Extension Downloader to download the extension and the Manage Extensions interface in CAST Server Manager to install the extension, any dependent extensions are automatically downloaded and installed for you. You do not need to do anything.
  • the JEE Analyzer is not a dependency, but since this extension is always installed with AIP, you do not need to do anything.

Download and installation instructions

Please see:

The latest release status of this extension can be seen when downloading it from the CAST Extend server.

Packaging, delivering and analyzing your source code

Once the extension is installed, no further configuration changes are required before you can package your source code and run an analysis. The process of packaging, delivering and analyzing your source code does not change in any way:

  • Package and deliver your application.
  • Analyze your delivered application source code.

What results can you expect?

Once the analysis/snapshot generation has completed, you can view the results in the normal manner (for example via CAST Enlighten):

Transactions

Click to enlarge


Structure of layout

Click to enlarge


Web services linker

Click to enlarge


Function points (when using CAIP ≥ 8.3.0)

Click to enlarge

Objects

The following objects are displayed in CAST Enlighten:

IconDescription

Button, ImageButton, RadioButton, Checkbox, Item

AutoCompleteTextView, Text View, Edit Text

Spinner, Time Picker, Relative Layout, Linear Layout, Menu, Group, ListView, WebView, GridView, UndefinedWidget.

Event handler

Get Resource Service

Put Resource Service

Post Resource Service

Delete Resource Service

Shared preferences, internal storage, external storage

Android Application

Android ui layout

Structural Rules

The following structural rules are provided:

Known limitations

  • CAST recommends using the most recent stable release of CAST AIP with the extension for best results.
  • Some links won't be resolved because of missing jar file.
  • Lambda expression is supported from CAST AIP 8.2.11. There are still some limitations for transactions.
  • Web Service URI name isn't stable for more complex situations.
  • Currently there is no discoverer available in the CAST Delivery Manager Tool, so the extension will not recognize Android projects. Users need to create JEE Analysis Units manually in order to analyze the Android application source code.