Crossfire JXClient, Trunk  R20561
com.realtime.crossfire.jxclient.util.Mapping Class Reference

Maintains a mapping from a set of integers to the same range of integers. More...

+ Collaboration diagram for com.realtime.crossfire.jxclient.util.Mapping:

Public Member Functions

void clear ()
 Removes all mappings. More...
 
int get (final int src)
 Returns a mapping. More...
 
void insert (final int src, final int dst)
 Adds a mapping. More...
 
void remove (final int src)
 Removes a mapping. More...
 

Private Attributes

final List< Integer > mapping = new ArrayList<>()
 The mappings. More...
 

Detailed Description

Maintains a mapping from a set of integers to the same range of integers.

Author
Andreas Kirschbaum

Definition at line 32 of file Mapping.java.

Member Function Documentation

◆ clear()

void com.realtime.crossfire.jxclient.util.Mapping.clear ( )

Removes all mappings.

Definition at line 43 of file Mapping.java.

Referenced by com.realtime.crossfire.jxclient.util.DoubleMapping.clear().

+ Here is the caller graph for this function:

◆ get()

int com.realtime.crossfire.jxclient.util.Mapping.get ( final int  src)

Returns a mapping.

Parameters
srcthe source index
Returns
the destination index

Definition at line 82 of file Mapping.java.

Referenced by com.realtime.crossfire.jxclient.util.DoubleMapping.getDst(), com.realtime.crossfire.jxclient.util.DoubleMapping.getSrc(), and com.realtime.crossfire.jxclient.util.DoubleMapping.remove().

+ Here is the caller graph for this function:

◆ insert()

void com.realtime.crossfire.jxclient.util.Mapping.insert ( final int  src,
final int  dst 
)

Adds a mapping.

Parameters
srcthe source index
dstthe destination index

Definition at line 52 of file Mapping.java.

Referenced by com.realtime.crossfire.jxclient.util.DoubleMapping.insert().

+ Here is the caller graph for this function:

◆ remove()

void com.realtime.crossfire.jxclient.util.Mapping.remove ( final int  src)

Removes a mapping.

Parameters
srcthe source index

Definition at line 66 of file Mapping.java.

Referenced by com.realtime.crossfire.jxclient.util.DoubleMapping.remove().

+ Here is the caller graph for this function:

Member Data Documentation

◆ mapping

final List<Integer> com.realtime.crossfire.jxclient.util.Mapping.mapping = new ArrayList<>()
private

The mappings.

Maps source index to destination index.

Definition at line 38 of file Mapping.java.


The documentation for this class was generated from the following file: