# API Overview

## **TotalCross Packages**

### totalcross.crypto

The classes used by TotalCross to work with encryption are:&#x20;

* **Cipher**: AES e RSA;
* **Digest**: MD5, SHA1, SHA256 ;
* **Signature**: PKCS1.

### totalcross.db e totalcross.sql

The **totalcross.db** package has SQLite Java implementation, the most widely used portable database in the world. Allows you to use SQL commands to manipulate data files lightly and with low memory consumption.

The t**otalcross.sql** package has JDBC implementation for use with SQLite - SQLiteUtil - as you can see in the code example below:

```java
public class DatabaseManager {

	public static SQLiteUtil sqliteUtil;

	static {
		try {
			sqliteUtil = new SQLiteUtil(Settings.appPath, "test.db");
			Statement st = sqliteUtil.con().createStatement();
			st.execute("create table if not exists person (cpf varchar)");
			st.close();

		} catch (SQLException e) {
			e.printStackTrace();
		}
	}
}
```

To learn more about SQLite, how to implement SQLite Useful, creating applications with database and CRUD just read the link session below:

{% content-ref url="broken-reference" %}
[Broken link](https://learn.totalcross.com/documentation/apis/broken-reference)
{% endcontent-ref %}

### totalcross.io

The totalcross.io package concentrates the classes used in input and output.

* ByteArrayStream
* DataStream&#x20;
* File&#x20;
  * BufferedStream&#x20;
* LineReader&#x20;
* device.bluetooth&#x20;
* device.gps&#x20;
* device.printer&#x20;
* device.scanner

### totalcross.json

In this class we have the json library in Java, a lot used in the creation of Web Services through Rest. To understand better, visit the session below:

{% content-ref url="json" %}
[json](https://learn.totalcross.com/documentation/apis/json)
{% endcontent-ref %}

### totalcross.map

Totalcross.map supports GoogleMaps and Waze. You can better understand by clicking on the session below:

{% content-ref url="maps" %}
[maps](https://learn.totalcross.com/documentation/apis/maps)
{% endcontent-ref %}

### totalcross.net&#x20;

It is in the package totalcross.net where the connection classes are. Are they:

* Socket FTP;
* HTTPStream;
* ServerSocket;
* mail (pop3);
* SSL

### totalcross.phone&#x20;

The classes responsible for handling telephones are:

* CellInfo&#x20;
* Dial&#x20;
* SMS

### totalcross.sys&#x20;

The totalcross.sys package contains the utility and usage classes for Virtual Machine. Are they:

* Convert&#x20;
* Setting&#x20;
* Time&#x20;
* VM

### totalcross.unit&#x20;

The classes responsible for building unit tests are in the totalcross.unit package. The classes are:&#x20;

* TestCase
* TestSuite
* UIRobot

### totalcross.util&#x20;

Utilities classes

* Date Hashtable / Vector
* IntHastable / IntVector&#x20;
* Random&#x20;
* Collections&#x20;
* concurrent.Lock&#x20;
* BigDecimal / BigInteger&#x20;
* PDFWritter&#x20;
* Regex&#x20;
* Zip/ZLib/GZip

### totalcross.xml

In the package totalcross.xml are the classes responsible for XML handling. They are:

* XMLRPC com Axis&#x20;
* SOAP
* XMLTokenizer

## References

* For a better understanding, see the [javadoc](http://rs.totalcross.com/doc/index.html)
