Index

Package: Tiles.Indices

Description

package Tiles.Indices is

Types

Tile_Index

type Tile_Index is private;

References:

tiles-indices.ads:11:10 (declaration)
tiles-indices.adb:92:46 (reference)
tiles-indices.adb:132:59 (reference)
tiles-indices.ads:12:37 (reference)
tiles-indices.ads:148:10 (full declaration)

A_Tile_Index

type A_Tile_Index is access all Tile_Index;

References:

tiles-indices.ads:12:10 (declaration)
tiles-indices.adb:91:39 (reference)
tiles-indices.adb:92:26 (reference)
tiles-indices.adb:101:53 (reference)
tiles-indices.adb:102:20 (reference)
tiles-indices.adb:108:18 (reference)
tiles-indices.adb:121:38 (reference)
tiles-indices.adb:132:71 (reference)
tiles-indices.adb:157:44 (reference)
tiles-indices.adb:165:42 (reference)
tiles-indices.adb:186:43 (reference)
tiles-indices.adb:196:49 (reference)
tiles-indices.adb:203:45 (reference)
tiles-indices.adb:210:41 (reference)
tiles-indices.adb:225:41 (reference)
tiles-indices.adb:235:41 (reference)
tiles-indices.adb:271:49 (reference)
tiles-indices.adb:282:47 (reference)
tiles-indices.adb:289:49 (reference)
tiles-indices.adb:303:47 (reference)
tiles-indices.adb:311:47 (reference)
tiles-indices.adb:326:49 (reference)
tiles-indices.adb:338:47 (reference)
tiles-indices.adb:344:13 (reference)
tiles-indices.adb:360:82 (reference)
tiles-indices.adb:361:19 (reference)
tiles-indices.adb:430:45 (reference)
tiles-indices.ads:13:32 (reference)
tiles-indices.ads:16:39 (reference)
tiles-indices.ads:22:53 (reference)
tiles-indices.ads:26:44 (reference)
tiles-indices.ads:32:42 (reference)
tiles-indices.ads:36:38 (reference)
tiles-indices.ads:41:43 (reference)
tiles-indices.ads:44:49 (reference)
tiles-indices.ads:47:45 (reference)
tiles-indices.ads:53:41 (reference)
tiles-indices.ads:57:41 (reference)
tiles-indices.ads:61:41 (reference)
tiles-indices.ads:66:49 (reference)
tiles-indices.ads:70:47 (reference)
tiles-indices.ads:74:49 (reference)
tiles-indices.ads:79:47 (reference)
tiles-indices.ads:82:47 (reference)
tiles-indices.ads:86:49 (reference)
tiles-indices.ads:89:47 (reference)
tiles-indices.ads:156:82 (reference)
tiles-indices.ads:157:9 (reference)
tiles-indices.ads:159:84 (reference)
tiles-indices.ads:160:9 (reference)
tiles-indices.ads:161:9 (reference)
tiles-libraries.ads:116:25 (reference)

Constants & Global variables

DUPLICATE_TILE

DUPLICATE_TILE : exception;

References:

tiles-indices.ads:101:5 (declaration)
tiles-indices.adb:173:27 (reference)

Subprograms & Entries

Create_Tile_Index

function Create_Tile_Index return A_Tile_Index;

References:

tiles-indices.ads:16:14 (declaration)
tiles-indices.adb:91:14 (body)
tiles-indices.adb:96:9 (label)
tiles-indices.adb:390:18 (reference)
tiles-indices.ads:17:27 (reference)
tiles-libraries.adb:165:23 (reference)

Called by:

A_Tile_Index_Input defined at tiles-indices.ads:156:14
Tiles.Libraries.Create_Library defined at tiles-libraries.ads:123:14
Creates a new empty tile index.

Load_Index

function Load_Index
( archive: not null A_Archive;
filename: String )
return A_Tile_Index;

References:

tiles-indices.ads:21:14 (declaration)
tiles-indices.adb:100:14 (body)
tiles-indices.adb:117:9 (label)
tiles-libraries-loading.adb:198:26 (reference)
Loads a tile index from an archive. Null will be returned if an error occurs.

Add_Matrix

procedure Add_Matrix
( index: not null A_Tile_Index;
matrix: in out A_Tile_Matrix );

References:

tiles-indices.ads:26:15 (declaration)
tiles-indices.adb:157:15 (body)
tiles-indices.adb:161:9 (label)
tiles-indices.adb:416:17 (reference)
tiles-libraries.adb:175:13 (reference)

Called by:

A_Tile_Index_Input defined at tiles-indices.ads:156:14
Tiles.Libraries.Add_Matrix defined at tiles-libraries.ads:134:15

Calls:

Append defined at a-convec.ads:199:14
Adds a new tile matrix to the index. 'matrix' will be consumed.

Add_Tile

procedure Add_Tile
( index: not null A_Tile_Index;
tile: in out A_Tile );

References:

tiles-indices.ads:32:15 (declaration)
tiles-indices.adb:165:15 (body)
tiles-indices.adb:182:9 (label)
tiles-indices.adb:405:17 (reference)
tiles-libraries.adb:186:13 (reference)

Called by:

A_Tile_Index_Input defined at tiles-indices.ads:156:14
Tiles.Libraries.Add_Tile defined at tiles-libraries.ads:143:15

Calls:

Add_Back defined at tiles-indices.ads:112:19
Append defined at a-convec.ads:199:14
Contains defined at a-cohama.ads:234:13
Insert defined at a-cohama.ads:158:14
Tiles.Get_Id defined at tiles.ads:50:14
Adds a new tile to the index. 'tile' is consumed. If 'tile' is passed as null, a null tile is added to the tile list as a place holder.

Delete

procedure Delete
( index: in out A_Tile_Index );

References:

tiles-indices.ads:36:15 (declaration)
tiles-indices.adb:121:15 (body)
tiles-indices.adb:153:9 (label)
tiles-indices.adb:423:13 (reference)
tiles-libraries.adb:216:9 (reference)

Called by:

A_Tile_Index_Input defined at tiles-indices.ads:156:14
Tiles.Libraries.Delete defined at tiles-libraries.ads:130:15

Calls:

Clear defined at a-convec.ads:95:14
Delete defined at tiles-indices.ads:136:15
Iterate defined at a-convec.ads:285:14
Iterate defined at a-cohama.ads:255:14
Tiles.Indices.Delete.Delete_Matrix defined at tiles-indices.adb:136:19
Tiles.Indices.Delete.Delete_Tile defined at tiles-indices.adb:125:19
Tiles.Indices.Delete.Free defined at tiles-indices.adb:132:19
Unchecked_Deallocation defined at a-uncdea.ads:20:15
Deletes a tile index.

Get_Matrix

function Get_Matrix
( index: not null A_Tile_Index;
num: Natural )
return A_Tile_Matrix;

References:

tiles-indices.ads:41:14 (declaration)
tiles-indices.adb:186:14 (body)
tiles-indices.adb:192:9 (label)
tiles-libraries.adb:335:16 (reference)

Calls:

Element defined at a-convec.ads:103:13
Length defined at a-convec.ads:87:13
Returns a reference to a matrix in the index by ordinal number. If there is no matrix for 'num' the null will be returned.

Get_Matrix_Count

function Get_Matrix_Count
( index: not null A_Tile_Index )
return Natural;

References:

tiles-indices.ads:44:14 (declaration)
tiles-indices.adb:196:14 (body)
tiles-indices.adb:199:9 (label)
tiles-libraries.adb:342:16 (reference)

Calls:

Length defined at a-convec.ads:87:13
Returns the number of matrices in the index.

Get_Progress

function Get_Progress
( index: not null A_Tile_Index )
return Natural;

References:

tiles-indices.ads:47:14 (declaration)
tiles-indices.adb:203:14 (body)
tiles-indices.adb:206:9 (label)
tiles-indices.ads:48:27 (reference)
tiles-libraries.adb:356:16 (reference)

Calls:

Get_Progress defined at tiles-indices.ads:115:18
Returns the load completion for the index in the range of 0..100

Get_Slot

function Get_Slot
( index: not null A_Tile_Index;
id: Natural )
return Natural;

References:

tiles-indices.ads:53:14 (declaration)
tiles-indices.adb:210:14 (body)
tiles-indices.adb:221:9 (label)
tiles-libraries.adb:365:20 (reference)

Calls:

Element defined at a-convec.ads:103:13
Length defined at a-convec.ads:87:13
Returns the slot number of a tile by id. The slot is determined by the order of the tiles in the index. The first tile is at slot 1. Zero will be returned if 'id' is not found in the index.

Get_Tile

function Get_Tile
( index: not null A_Tile_Index;
id: Natural )
return A_Tile;

References:

tiles-indices.ads:57:14 (declaration)
tiles-indices.adb:225:14 (body)
tiles-indices.adb:231:9 (label)
tiles-libraries.adb:226:20 (reference)
tiles-libraries.adb:238:21 (reference)
tiles-libraries.adb:257:21 (reference)
tiles-libraries.adb:295:21 (reference)
tiles-libraries.adb:376:20 (reference)

Calls:

Element defined at a-cohama.ads:237:13
Returns a tile reference by tile id. Do not modify the tile, it belongs to the index. Null will be returned if the tile is not found.

Get_Tile

function Get_Tile
( index: not null A_Tile_Index;
name: String )
return A_Tile;

References:

tiles-indices.ads:61:14 (declaration)
tiles-indices.adb:235:14 (body)
tiles-indices.adb:267:9 (label)
tiles-libraries.adb:307:35 (reference)

Calls:

Support.Paths.Add_Extension defined at support-paths.ads:7:14
Support.Paths.Get_Extension defined at support-paths.ads:32:14
Tiles.Indices.Get_Tile.Find_Tile defined at tiles-indices.adb:239:18
Returns a tile reference by name. Do not modify the tile, it belongs to the index. Null will be returned if the tile is not found.

Get_Tile_At_Slot

function Get_Tile_At_Slot
( index: not null A_Tile_Index;
slot: Natural )
return A_Tile;

References:

tiles-indices.ads:66:14 (declaration)
tiles-indices.adb:271:14 (body)
tiles-indices.adb:278:9 (label)
tiles-libraries.adb:276:21 (reference)
tiles-libraries.adb:322:21 (reference)

Calls:

Element defined at a-cohama.ads:237:13
Element defined at a-convec.ads:103:13
Returns a tile reference by slot number. Do not modify the tile, it belongs to the index. Null will be returned if the tile is not found.

Get_Tile_Count

function Get_Tile_Count
( index: not null A_Tile_Index )
return Natural;

References:

tiles-indices.ads:70:14 (declaration)
tiles-indices.adb:282:14 (body)
tiles-indices.adb:285:9 (label)
tiles-libraries.adb:385:16 (reference)

Calls:

Length defined at a-convec.ads:87:13
Returns the number of tiles in the index.

Iterate_Tiles

procedure Iterate_Tiles
( index: not null A_Tile_Index;
examine: not null access procedure( tile : A_Tile )
);

References:

tiles-indices.ads:74:15 (declaration)
tiles-indices.adb:289:15 (body)
tiles-indices.adb:299:9 (label)

Calls:

Iterate defined at a-cohama.ads:255:14
Tiles.Indices.Iterate_Tiles.Local_Examine defined at tiles-indices.adb:292:19
Iterates across the tiles in the index by order of listing, from first to last.

Load_Complete

procedure Load_Complete
( index: not null A_Tile_Index );

References:

tiles-indices.ads:79:15 (declaration)
tiles-indices.adb:303:15 (body)
tiles-indices.adb:307:9 (label)
tiles-libraries-loading.adb:115:13 (reference)
tiles-libraries-loading.adb:130:17 (reference)

Called by:

Tiles.Libraries.Loading.Loading_Task defined at tiles-libraries-loading.adb:93:15
Tiles.Libraries.Loading.Loading_Task defined at tiles-libraries-loading.adb:93:15

Calls:

Stop defined at tiles-indices.ads:126:19
Indicates to the index that all tiles have been loaded. This will free up any threads waiting for the index to be fully loaded.

Load_Images

procedure Load_Images
( index: not null A_Tile_Index;
archive: not null A_Archive );

References:

tiles-indices.ads:82:15 (declaration)
tiles-indices.adb:311:15 (body)
tiles-indices.adb:322:9 (label)
tiles-libraries-loading.adb:110:13 (reference)

Called by:

Tiles.Libraries.Loading.Loading_Task defined at tiles-libraries-loading.adb:93:15

Calls:

Remove defined at tiles-indices.ads:123:19
Stop defined at tiles-indices.ads:126:19
Tiles.Load_Bitmap defined at tiles.ads:136:15
Loads all the bitmaps for all the tiles in the index.

Prioritize_Tile

procedure Prioritize_Tile
( index: not null A_Tile_Index;
tile: not null A_Tile );

References:

tiles-indices.ads:86:15 (declaration)
tiles-indices.adb:326:15 (body)
tiles-indices.adb:334:9 (label)
tiles-libraries.adb:243:21 (reference)
tiles-libraries.adb:260:21 (reference)
tiles-libraries.adb:281:21 (reference)
Prioritizes a tile to be loaded before non-priority tiles.

Write_Index

function Write_Index
( index: not null A_Tile_Index;
filename: String )
return Boolean;

References:

tiles-indices.ads:89:14 (declaration)
tiles-indices.adb:338:14 (body)
tiles-indices.adb:356:9 (label)

Calls:

Close defined at a-ststio.ads:80:14
Create defined at a-ststio.ads:68:14
Index_Extension defined at tiles-indices.ads:95:14
Is_Open defined at a-ststio.ads:89:13
Stream defined at a-ststio.ads:92:13
Support.Paths.Add_Extension defined at support-paths.ads:7:14
Writes the index to a file on disk, returning True on success.

Index_Extension

function Index_Extension return String;

References:

tiles-indices.ads:95:14 (declaration)
tiles-indices.adb:342:58 (reference)
tiles-indices.adb:456:14 (body)
tiles-indices.adb:459:9 (label)
tiles-indices.adb:465:40 (reference)
tiles-indices.ads:96:27 (reference)
tiles-libraries-loading.adb:180:61 (reference)

Index_Identifier

function Index_Identifier return String;

References:

tiles-indices.ads:98:14 (declaration)
tiles-indices.adb:362:38 (reference)
tiles-indices.adb:434:31 (reference)
tiles-indices.adb:463:14 (body)
tiles-indices.adb:466:9 (label)
tiles-indices.ads:99:27 (reference)

Called by:

A_Tile_Index_Input defined at tiles-indices.ads:156:14
A_Tile_Index_Output defined at tiles-indices.ads:159:15

Calls:

Index_Extension defined at tiles-indices.ads:95:14
Tiles.Tile_Identifier defined at tiles.ads:171:14